ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   VB macro code does not save (https://www.excelbanter.com/excel-programming/415735-vbulletin-macro-code-does-not-save.html)

Mary G

VB macro code does not save
 
I've inherited a spreadsheet with a macro that needs to be updated. We are
moving data from one spreadsheet to another using this:
ws.Cells(i, 4) = aLine(3)
ws.Cells(i, 5) = aLine(4)
ws.Cells(i, 6) = aLine(6)
ws.Cells(i, 7) = aLine(7)

All I need to do is update the numbers and it works correctly. But when I go
into that spreadsheet the next day, the number have reverted back to the
originals. Any ideas??? I confirmed that the file was saved and it appeared
to work correctly when it was copied over for another department to access.
Any help would be greatly appreciated!
--
Mary

Héctor Miguel

VB macro code does not save
 
hi, Mary !

- what happens *if* you close and (re)open your file just after the update ?

- if (re)opening "reverts" the update...
how can you be sure (and confirm that) the file is (really) saved ?

- revise any code / procedure which could "cancel" the '_beforesave' event
(within ThisWorkbook code module)

hth,
hector.

__ OP __
I've inherited a spreadsheet with a macro that needs to be updated.
We are moving data from one spreadsheet to another using this:
ws.Cells(i, 4) = aLine(3)
ws.Cells(i, 5) = aLine(4)
ws.Cells(i, 6) = aLine(6)
ws.Cells(i, 7) = aLine(7)
All I need to do is update the numbers and it works correctly.
But when I go into that spreadsheet the next day, the number have reverted back to the originals.
Any ideas??? I confirmed that the file was saved and it appeared to work correctly
when it was copied over for another department to access.
Any help would be greatly appreciated!





All times are GMT +1. The time now is 06:17 AM.

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