Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I have a macro in ThisWorkbook in a workbook named Template, that will
make sure a column is cleared before the user starts. This, in case someone saves data in this workbook by accident. The user will run other macros, and eventually a macro will save this workbook under a new name based on the date, example NewFile 1-1-07 . However, if the user brings up this workbook NewFile 1-1-07 again later, this column will be wiped out via the ThisWorkbook coding. What I want is to include code within the macros that will disable the code in ThisWorkbook so that column is not wiped out when it is opened later. Thanks, J.O. |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I dont think you can disable the code when doing a save as What uo could do
instead of save as is to copy to a new book so that the code will not follow the workbook. Add or Subract sheets that you need Sheets(Array("Sheet1", "Sheet2", "Sheet3")).Select Sheets(Array("Sheet1", "Sheet2", "Sheet3")).Copy "excelnut1954" wrote: I have a macro in ThisWorkbook in a workbook named Template, that will make sure a column is cleared before the user starts. This, in case someone saves data in this workbook by accident. The user will run other macros, and eventually a macro will save this workbook under a new name based on the date, example NewFile 1-1-07 . However, if the user brings up this workbook NewFile 1-1-07 again later, this column will be wiped out via the ThisWorkbook coding. What I want is to include code within the macros that will disable the code in ThisWorkbook so that column is not wiped out when it is opened later. Thanks, J.O. |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
On May 2, 11:45 am, Mike wrote:
I dont think you can disable the code when doing a save as What uo could do instead of save as is to copy to a new book so that the code will not follow the workbook. Add or Subract sheets that you need Sheets(Array("Sheet1", "Sheet2", "Sheet3")).Select Sheets(Array("Sheet1", "Sheet2", "Sheet3")).Copy "excelnut1954" wrote: I have a macro in ThisWorkbook in a workbook named Template, that will make sure a column is cleared before the user starts. This, in case someone saves data in this workbook by accident. The user will run other macros, and eventually a macro will save this workbook under a new name based on the date, example NewFile 1-1-07 . However, if the user brings up this workbook NewFile 1-1-07 again later, this column will be wiped out via the ThisWorkbook coding. What I want is to include code within the macros that will disable the code in ThisWorkbook so that column is not wiped out when it is opened later. Thanks, J.O.- Hide quoted text - - Show quoted text - Thanks Mike I wasn't sure if you could have a macro write to a macro, especially since I have the VB window password protected. I'll try your method. If someone else has an idea, I would appreciate it. Thanks again for your suggestion, Mike. J.O. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Disable Quick Save & Save As | Excel Discussion (Misc queries) | |||
Disable save & save as then return message... | Excel Programming | |||
disable save and saveas from menubar and save via command button | Excel Programming | |||
Disable save, save as, but allow save via command button | Excel Programming | |||
Disable File-Save menu item in macro? | Excel Programming |