Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
I have a large file which I open frequently, and it drives me crazy if I
forget to turn off automatic calculation, as it can take 10 minutes to calculate - I usually crash out of Excel to stop it. I added code to switch calculation to manual as the workbook opens, but unfortunately, that workbook_open procedure seems to fire after the workbook has been through the calculation process. Is there any code that runs immediately when a file is opened? Thanks in advance Daniel |
#2
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Hi Daniel,
there's an easy way - without any programming... ;) Simply load the file and (unfortunately you'll have to wait this time till' it has calculated - have you every tried to hit "Esc" during calculation?) Now, you select "Tools" - "Macros" - "Visual Basic-Editor". In the Project Explorer you'll see the sheets of your workbook. Select the one which has these tremendous calculations. Now you should see in the properties of the sheet the property "EnableCalculation". Set this to False and you're done. Now the sheet only calculates if you hit "F9"... ;) Hope this helps and best wishes, Eric "Daniel Bonallack" wrote: I have a large file which I open frequently, and it drives me crazy if I forget to turn off automatic calculation, as it can take 10 minutes to calculate - I usually crash out of Excel to stop it. I added code to switch calculation to manual as the workbook opens, but unfortunately, that workbook_open procedure seems to fire after the workbook has been through the calculation process. Is there any code that runs immediately when a file is opened? Thanks in advance Daniel |
#3
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Wow - a fabulous solution! Thanks!
"Eric_MUC" wrote: Hi Daniel, there's an easy way - without any programming... ;) Simply load the file and (unfortunately you'll have to wait this time till' it has calculated - have you every tried to hit "Esc" during calculation?) Now, you select "Tools" - "Macros" - "Visual Basic-Editor". In the Project Explorer you'll see the sheets of your workbook. Select the one which has these tremendous calculations. Now you should see in the properties of the sheet the property "EnableCalculation". Set this to False and you're done. Now the sheet only calculates if you hit "F9"... ;) Hope this helps and best wishes, Eric "Daniel Bonallack" wrote: I have a large file which I open frequently, and it drives me crazy if I forget to turn off automatic calculation, as it can take 10 minutes to calculate - I usually crash out of Excel to stop it. I added code to switch calculation to manual as the workbook opens, but unfortunately, that workbook_open procedure seems to fire after the workbook has been through the calculation process. Is there any code that runs immediately when a file is opened? Thanks in advance Daniel |
#4
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
You sure that it calculates when you hit F9??
From VBA's help for the .enablecalculation property: When the value of this property is False, you cannot request a recalculation. When you change the value from False to True, Excel recalculates the worksheet. Eric_MUC wrote: Hi Daniel, there's an easy way - without any programming... ;) Simply load the file and (unfortunately you'll have to wait this time till' it has calculated - have you every tried to hit "Esc" during calculation?) Now, you select "Tools" - "Macros" - "Visual Basic-Editor". In the Project Explorer you'll see the sheets of your workbook. Select the one which has these tremendous calculations. Now you should see in the properties of the sheet the property "EnableCalculation". Set this to False and you're done. Now the sheet only calculates if you hit "F9"... ;) Hope this helps and best wishes, Eric "Daniel Bonallack" wrote: I have a large file which I open frequently, and it drives me crazy if I forget to turn off automatic calculation, as it can take 10 minutes to calculate - I usually crash out of Excel to stop it. I added code to switch calculation to manual as the workbook opens, but unfortunately, that workbook_open procedure seems to fire after the workbook has been through the calculation process. Is there any code that runs immediately when a file is opened? Thanks in advance Daniel -- Dave Peterson |
#5
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
I think I'd use a helper workbook that turns off calculation, then loads your
real file. Daniel Bonallack wrote: I have a large file which I open frequently, and it drives me crazy if I forget to turn off automatic calculation, as it can take 10 minutes to calculate - I usually crash out of Excel to stop it. I added code to switch calculation to manual as the workbook opens, but unfortunately, that workbook_open procedure seems to fire after the workbook has been through the calculation process. Is there any code that runs immediately when a file is opened? Thanks in advance Daniel -- Dave Peterson |
#6
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Hi Dave,
I tried it - it does....at least in my MS Excel... ;) Best wishes, Eric "Dave Peterson" wrote: You sure that it calculates when you hit F9?? From VBA's help for the .enablecalculation property: When the value of this property is False, you cannot request a recalculation. When you change the value from False to True, Excel recalculates the worksheet. Eric_MUC wrote: Hi Daniel, there's an easy way - without any programming... ;) Simply load the file and (unfortunately you'll have to wait this time till' it has calculated - have you every tried to hit "Esc" during calculation?) Now, you select "Tools" - "Macros" - "Visual Basic-Editor". In the Project Explorer you'll see the sheets of your workbook. Select the one which has these tremendous calculations. Now you should see in the properties of the sheet the property "EnableCalculation". Set this to False and you're done. Now the sheet only calculates if you hit "F9"... ;) Hope this helps and best wishes, Eric "Daniel Bonallack" wrote: I have a large file which I open frequently, and it drives me crazy if I forget to turn off automatic calculation, as it can take 10 minutes to calculate - I usually crash out of Excel to stop it. I added code to switch calculation to manual as the workbook opens, but unfortunately, that workbook_open procedure seems to fire after the workbook has been through the calculation process. Is there any code that runs immediately when a file is opened? Thanks in advance Daniel -- Dave Peterson |
#7
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Hi Dave,
to make sure I'm not wrong I re-tried it and this is very strange: Some calculations are done - some not.... e.g. "SUM" is not calculated while "Now" is calculated when hitting F9. OK...to ensure calculation is possible, I'd add either a button on the worksheet or assign a macro to a shortcut to make it calculate (by setting worksheet.enablecalculation=True and after calculation again to "False". This would enable me to calculate the sheet whenever I (and not Excel ;) ) want to but I'd be sure to use False as a standard. Best wishes, Eric "Dave Peterson" wrote: You sure that it calculates when you hit F9?? From VBA's help for the .enablecalculation property: When the value of this property is False, you cannot request a recalculation. When you change the value from False to True, Excel recalculates the worksheet. Eric_MUC wrote: Hi Daniel, there's an easy way - without any programming... ;) Simply load the file and (unfortunately you'll have to wait this time till' it has calculated - have you every tried to hit "Esc" during calculation?) Now, you select "Tools" - "Macros" - "Visual Basic-Editor". In the Project Explorer you'll see the sheets of your workbook. Select the one which has these tremendous calculations. Now you should see in the properties of the sheet the property "EnableCalculation". Set this to False and you're done. Now the sheet only calculates if you hit "F9"... ;) Hope this helps and best wishes, Eric "Daniel Bonallack" wrote: I have a large file which I open frequently, and it drives me crazy if I forget to turn off automatic calculation, as it can take 10 minutes to calculate - I usually crash out of Excel to stop it. I added code to switch calculation to manual as the workbook opens, but unfortunately, that workbook_open procedure seems to fire after the workbook has been through the calculation process. Is there any code that runs immediately when a file is opened? Thanks in advance Daniel -- Dave Peterson |
#8
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]() Eric_MUC Wrote: Hi Daniel, there's an easy way - without any programming... ;) Simply load the file and (unfortunately you'll have to wait this time till' it has calculated - have you every tried to hit "Esc" during calculation?) Now, you select "Tools" - "Macros" - "Visual Basic-Editor". In the Project Explorer you'll see the sheets of your workbook. Select the one which has these tremendous calculations. Now you should see in the properties of the sheet the property "EnableCalculation". Set this to False and you're done. Now the sheet only calculates if you hit "F9"... ;) Hope this helps and best wishes, Eric "Daniel Bonallack" wrote: I have a large file which I open frequently, and it drives me crazy if I forget to turn off automatic calculation, as it can take 10 minutes to calculate - I usually crash out of Excel to stop it. I added code to switch calculation to manual as the workbook opens, but unfortunately, that workbook_open procedure seems to fire after the workbook has been through the calculation process. Is there any code that runs immediately when a file is opened? Thanks in advance Daniel HI I´m trying to use option of setting enablecalculation to false, but when I reopen the document this property is set to true again. I´m saving the document after setting enable calculation to false, but it doesn´t work. -- RSantos ------------------------------------------------------------------------ RSantos's Profile: http://www.excelforum.com/member.php...o&userid=31240 View this thread: http://www.excelforum.com/showthread...hreadid=511965 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
excel does not open files on double click | Setting up and Configuration of Excel | |||
cannot open an xl97 file | Excel Discussion (Misc queries) | |||
How do I find a file/spreadsheet that Excel says is Already open but I can't find it? | Excel Discussion (Misc queries) | |||
How do I stop the activeX screen appearing when I open excel | Excel Discussion (Misc queries) | |||
Formulas stop calculating at random times when editing a few spreadsheets. | Excel Discussion (Misc queries) |