Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Data being saved in error (?)
Hi all...
I am running a pretty long series of reports. The data is refreshed daily via iSeries data file transfers, and is then brought into several different reports/spreadsheets. However, I just noticed, that one data file keeps getting overwritten - how I am not sure since there is no command to save the file any where in my code. The chunk of code that is causing the proplem rearranges some columns then filters the data file based on one column, copies the range of information and pastes it to the report file. Fairly simple I thought... until I noticed the data filed saved with the rearranged columns and filtered on the last criteria used. To close the file, I used: Application.CutCopyMode = False Windows("data.xls").Activate ActiveWorkbook.Close SaveChanges = False Would an autofilter cause the file to save on its own? I need this data to save back to the original format so I can use it in other reports. |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Data being saved in error (?)
ActiveWorkbook.Close SaveChanges = False
should be ActiveWorkbook.Close SaveChanges:=False -- Regards, Tom Ogilvy "NewBike" wrote: Hi all... I am running a pretty long series of reports. The data is refreshed daily via iSeries data file transfers, and is then brought into several different reports/spreadsheets. However, I just noticed, that one data file keeps getting overwritten - how I am not sure since there is no command to save the file any where in my code. The chunk of code that is causing the proplem rearranges some columns then filters the data file based on one column, copies the range of information and pastes it to the report file. Fairly simple I thought... until I noticed the data filed saved with the rearranged columns and filtered on the last criteria used. To close the file, I used: Application.CutCopyMode = False Windows("data.xls").Activate ActiveWorkbook.Close SaveChanges = False Would an autofilter cause the file to save on its own? I need this data to save back to the original format so I can use it in other reports. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
"File Error: Data May Be Lost" when file saved on Mac is opened inWindows | Excel Discussion (Misc queries) | |||
need to retrieve data that was saved in error | Excel Discussion (Misc queries) | |||
Document Not Saved Error | Excel Discussion (Misc queries) | |||
Error when opening a saved worksheet | Excel Worksheet Functions | |||
Automation Error and Document not saved | Excel Programming |