Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
VBA UDF Calculation (not)
To all,
I've got a UDF, but Excel will only calc it when the cell containing it is edited, ie, F2, enter. How can I force a calc? I tried 'Calculate' on the SheetActivate event, and nothing happens... TIA, Greg |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
VBA UDF Calculation (not)
What are the inputs to the UDF? Does it use any data not passed as a parameter?
-- Tim Williams Palo Alto, CA "Greg Longtin" wrote in message ... To all, I've got a UDF, but Excel will only calc it when the cell containing it is edited, ie, F2, enter. How can I force a calc? I tried 'Calculate' on the SheetActivate event, and nothing happens... TIA, Greg |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
VBA UDF Calculation (not)
Tim,
What are the inputs to the UDF? Does it use any data not passed as a parameter? One cell value, which is the name a worksheet in the workbook to use for the calculation. Greg |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
VBA UDF Calculation (not)
Greg,
Excel normally does not recalculate functions if their inputs have not changed. But may be application.Volatile will give the desired behaviour. NickHK "Greg Longtin" wrote in message ... Tim, What are the inputs to the UDF? Does it use any data not passed as a parameter? One cell value, which is the name a worksheet in the workbook to use for the calculation. Greg |
#5
Posted to microsoft.public.excel.programming
|
|||
|
|||
VBA UDF Calculation (not) solution
Tim,
Found a solution. Simply put, the udf find a date in other sheets, and it's used in a summary sheet. I orginally set it up with one parameter, which tells it what sheet to use. The workbook is a summary of our truck maintanance (one sheet per), and the udf is used in the summary page. Anyway, the summary sheet has a cell that uses TODAY() for revision date. I added this as a parameter to the UDF, and although I'm not using it for anything, it forces the recalc. Thanks, Greg |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
calculation msg box | Excel Discussion (Misc queries) | |||
Multi threaded calculation (multi CPU) - impact on calculation spe | Excel Discussion (Misc queries) | |||
How do I use a rounded calculation result in another calculation? | Excel Worksheet Functions | |||
How do I use a rounded calculation result in another calculation? | Excel Worksheet Functions | |||
range.calculation with UDF not working when calculation is set to automatic | Excel Programming |