I have some VBA that refreshes several queries on several worksheets.
The VBA then saves the spreadsheet as a given name on the C:\ drive of my PC.
When it runs it just replaces the source spreadsheet with the saved one.
There's a couple of problems now.
1) there is a combo box on the first worksheet. If I select a different worksheet, I can still see the combo box on the screen in the same space - obscuring all of the worksheet data.
2) If I select a sheet sometimes, Excel just crashes.
If I then close down Excel, reopen the saved file and disable the macros, its all fine.
how can I tell VBA to NOT enable the macros when it saves a file?
is it just a case of copying all data, and pasting it into a new spreadsheet before saving it??
The VBA then saves the spreadsheet as a given name on the C:\ drive of my PC.
When it runs it just replaces the source spreadsheet with the saved one.
There's a couple of problems now.
1) there is a combo box on the first worksheet. If I select a different worksheet, I can still see the combo box on the screen in the same space - obscuring all of the worksheet data.
2) If I select a sheet sometimes, Excel just crashes.
If I then close down Excel, reopen the saved file and disable the macros, its all fine.
how can I tell VBA to NOT enable the macros when it saves a file?
is it just a case of copying all data, and pasting it into a new spreadsheet before saving it??