ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   VBA code gets lost from workbook if I paste in new data and save??? (https://www.excelbanter.com/excel-programming/294600-vba-code-gets-lost-workbook-if-i-paste-new-data-save.html)

Lonnie[_3_]

VBA code gets lost from workbook if I paste in new data and save???
 
Any ideas that you may have to help me prevent this is greatly
appreciated.I have written an application in excel 97 running on
Windows 2000. The application takes data from a sheet that I manually
paste the data into and then creates a batch of files based on that
data. I can open, close, save, and 'save as' as often as I like, until
I paste in new data and save/'save as'. Once I open it, after having
pasted new data, there is no longer any VBA code, the buttons are
still there, but there is no property information--nor am I prompted
to enable macros when I open it???


Thank you in advance--Lonnie

Tom Ogilvy

VBA code gets lost from workbook if I paste in new data and save???
 
Check what format you are saving the workbook in. In Tools=Options,
Transition Tab, the first dropdown should say

Microsoft Excel Workbook rather than something like

Microsoft Excel 5.0/95 Workbook or anything else.

--
Regards,
Tom Ogilvy

"Lonnie" wrote in message
om...
Any ideas that you may have to help me prevent this is greatly
appreciated.I have written an application in excel 97 running on
Windows 2000. The application takes data from a sheet that I manually
paste the data into and then creates a batch of files based on that
data. I can open, close, save, and 'save as' as often as I like, until
I paste in new data and save/'save as'. Once I open it, after having
pasted new data, there is no longer any VBA code, the buttons are
still there, but there is no property information--nor am I prompted
to enable macros when I open it???


Thank you in advance--Lonnie





All times are GMT +1. The time now is 08:47 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com