Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Application.Calculate
Hi!
I have an excel file that calculate 10 000 simulations. For each simulation, I use the Application.Calculate (takes 3 seconds) to refresh the result. Thereafter, I copy the interesting result inside a cell and I do it for all simulations. The problem I have is that Application.Calculate doesn't refresh all the workbook. File= 130 mo. Is there anything else I can write to ensure all calculations have been done? Thank you! Alex -- Alex St-Pierre |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Application.Calculate
Hi,
Are you using "application.volatile = false"? Does the status bar say "Calculate" even after you do a manual calculation? On Oct 4, 2:49 pm, Alex St-Pierre wrote: Hi! I have an excel file that calculate 10 000 simulations. For each simulation, I use the Application.Calculate (takes 3 seconds) to refresh the result. Thereafter, I copy the interesting result inside a cell and I do it for all simulations. The problem I have is that Application.Calculate doesn't refresh all the workbook. File= 130 mo. Is there anything else I can write to ensure all calculations have been done? Thank you! Alex -- Alex St-Pierre |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Application.Calculate
Hi!
Are you using "application.volatile = false"? I don't know this function Does the status bar say "Calculate" even after you do a manual calculation? It takes 3 seconds to calculate as when I do an "Application.Calculate". When this is done, the status bar indicate doesn't indicate calculate.. Sometimes, I do a F9 and even after the calculation, the results have changed but the data is not correct. Then, if I go in the cell that make the "=average(C2:M1000)" and edit the function, the value is changing when I press Enter.. This happens not often but should not happens. I don't know if there's a way to be sure all calculations are done in VBA? Thanks a lot! Alex -- Alex St-Pierre "JP" wrote: Hi, Are you using "application.volatile = false"? Does the status bar say "Calculate" even after you do a manual calculation? On Oct 4, 2:49 pm, Alex St-Pierre wrote: Hi! I have an excel file that calculate 10 000 simulations. For each simulation, I use the Application.Calculate (takes 3 seconds) to refresh the result. Thereafter, I copy the interesting result inside a cell and I do it for all simulations. The problem I have is that Application.Calculate doesn't refresh all the workbook. File= 130 mo. Is there anything else I can write to ensure all calculations have been done? Thank you! Alex -- Alex St-Pierre |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Application.Calculate
Alex,
You could try "Application.CalculateFull" in your routine, that will force a full calculation of all the data in all open workbooks. But it sounds like Excel is having trouble keeping track of all your formulas, you might want to try some ways to make your data more compact so Excel isn't working so hard. Hope this helps, JP On Oct 4, 6:25 pm, Alex St-Pierre wrote: Hi!Are you using "application.volatile = false"? I don't know this functionDoes the status bar say "Calculate" even after you do a manual calculation? It takes 3 seconds to calculate as when I do an "Application.Calculate". When this is done, the status bar indicate doesn't indicate calculate.. Sometimes, I do a F9 and even after the calculation, the results have changed but the data is not correct. Then, if I go in the cell that make the "=average(C2:M1000)" and edit the function, the value is changing when I press Enter.. This happens not often but should not happens. I don't know if there's a way to be sure all calculations are done in VBA? Thanks a lot! Alex -- Alex St-Pierre |
#5
Posted to microsoft.public.excel.programming
|
|||
|
|||
Application.Calculate
Yeah.. The problem is the calculation are so complex. There's no equation..
we must find the solution using simulation. Is there a way to make a break between each record or a wait .. I'll try it. Thanks! Alex -- Alex St-Pierre "JP" wrote: Alex, You could try "Application.CalculateFull" in your routine, that will force a full calculation of all the data in all open workbooks. But it sounds like Excel is having trouble keeping track of all your formulas, you might want to try some ways to make your data more compact so Excel isn't working so hard. Hope this helps, JP On Oct 4, 6:25 pm, Alex St-Pierre wrote: Hi!Are you using "application.volatile = false"? I don't know this functionDoes the status bar say "Calculate" even after you do a manual calculation? It takes 3 seconds to calculate as when I do an "Application.Calculate". When this is done, the status bar indicate doesn't indicate calculate.. Sometimes, I do a F9 and even after the calculation, the results have changed but the data is not correct. Then, if I go in the cell that make the "=average(C2:M1000)" and edit the function, the value is changing when I press Enter.. This happens not often but should not happens. I don't know if there's a way to be sure all calculations are done in VBA? Thanks a lot! Alex -- Alex St-Pierre |
#6
Posted to microsoft.public.excel.programming
|
|||
|
|||
Application.Calculate
I tried a wait but the problem is that there's no excel calculation during
that time.. I would like to let excel calculate but the wait seems to stop the excel calculation... Any idea? Thanks! Alex -- Alex St-Pierre "JP" wrote: Alex, You could try "Application.CalculateFull" in your routine, that will force a full calculation of all the data in all open workbooks. But it sounds like Excel is having trouble keeping track of all your formulas, you might want to try some ways to make your data more compact so Excel isn't working so hard. Hope this helps, JP On Oct 4, 6:25 pm, Alex St-Pierre wrote: Hi!Are you using "application.volatile = false"? I don't know this functionDoes the status bar say "Calculate" even after you do a manual calculation? It takes 3 seconds to calculate as when I do an "Application.Calculate". When this is done, the status bar indicate doesn't indicate calculate.. Sometimes, I do a F9 and even after the calculation, the results have changed but the data is not correct. Then, if I go in the cell that make the "=average(C2:M1000)" and edit the function, the value is changing when I press Enter.. This happens not often but should not happens. I don't know if there's a way to be sure all calculations are done in VBA? Thanks a lot! Alex -- Alex St-Pierre |
#7
Posted to microsoft.public.excel.programming
|
|||
|
|||
Application.Calculate
Does the status bar say "Calculate" even after you do a manual
calculation? Yes,.. it's always written Calculate... (the calculation are set to manual) -- Alex St-Pierre "JP" wrote: Hi, Are you using "application.volatile = false"? Does the status bar say "Calculate" even after you do a manual calculation? On Oct 4, 2:49 pm, Alex St-Pierre wrote: Hi! I have an excel file that calculate 10 000 simulations. For each simulation, I use the Application.Calculate (takes 3 seconds) to refresh the result. Thereafter, I copy the interesting result inside a cell and I do it for all simulations. The problem I have is that Application.Calculate doesn't refresh all the workbook. File= 130 mo. Is there anything else I can write to ensure all calculations have been done? Thank you! Alex -- Alex St-Pierre |
#8
Posted to microsoft.public.excel.programming
|
|||
|
|||
Application.Calculate
Maybe if you posted the code or the formulas you are using and/or some
more detail about what exactly you are doing, we could be of more assistance. --JP On Oct 4, 8:04 pm, Alex St-Pierre wrote: I tried a wait but the problem is that there's no excel calculation during that time.. I would like to let excel calculate but the wait seems to stop the excel calculation... Any idea? Thanks! Alex -- Alex St-Pierre |
#9
Posted to microsoft.public.excel.programming
|
|||
|
|||
Application.Calculate
Hi Alex,
You could try to rebuild the dependency tree with CTRL+ALT+SHIFT+F9. For lots of information about calculations in Excel, visit Charles William's site: www.decisionmodels.com -- Kind regards, Niek Otten Microsoft MVP - Excel "Alex St-Pierre" wrote in message ... | Hi! | Are you using "application.volatile = false"? | I don't know this function | Does the status bar say "Calculate" even after you do a manual | calculation? | It takes 3 seconds to calculate as when I do an "Application.Calculate". | When this is done, the status bar indicate doesn't indicate calculate.. | Sometimes, I do a F9 and even after the calculation, the results have changed | but the data is not correct. Then, if I go in the cell that make the | "=average(C2:M1000)" and edit the function, the value is changing when I | press Enter.. This happens not often but should not happens. I don't know if | there's a way to be sure all calculations are done in VBA? | Thanks a lot! | Alex | -- | Alex St-Pierre | | | "JP" wrote: | | Hi, | Are you using "application.volatile = false"? | | Does the status bar say "Calculate" even after you do a manual | calculation? | | | | On Oct 4, 2:49 pm, Alex St-Pierre | wrote: | Hi! | I have an excel file that calculate 10 000 simulations. For each simulation, | I use the Application.Calculate (takes 3 seconds) to refresh the result. | Thereafter, I copy the interesting result inside a cell and I do it for all | simulations. The problem I have is that Application.Calculate doesn't refresh | all the workbook. File= 130 mo. | Is there anything else I can write to ensure all calculations have been done? | Thank you! | Alex | -- | Alex St-Pierre | | | |
#10
Posted to microsoft.public.excel.programming
|
|||
|
|||
Application.Calculate
Alex St-Pierre,
I agree with JP - can you post the code you are using. It sounds like a lot of variables are in the spreadsheet. Do the calculations work when you do a manual update? "Alex St-Pierre" wrote: Hi! I have an excel file that calculate 10 000 simulations. For each simulation, I use the Application.Calculate (takes 3 seconds) to refresh the result. Thereafter, I copy the interesting result inside a cell and I do it for all simulations. The problem I have is that Application.Calculate doesn't refresh all the workbook. File= 130 mo. Is there anything else I can write to ensure all calculations have been done? Thank you! Alex -- Alex St-Pierre |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Run-time error '1004' at "Application.Calculate" | Excel Programming | |||
Application.Calculate vs. F9 | Excel Programming | |||
Application.Calculate & VLOOKUP | Excel Programming | |||
Application.Calculate & VLOOKUP | Excel Programming | |||
"Application.Calculate" does not always update/recalculate the for | Excel Programming |