Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 15
Default 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   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6,953
Default 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
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
"File Error: Data May Be Lost" when file saved on Mac is opened inWindows Игорь Excel Discussion (Misc queries) 0 December 28th 09 03:32 PM
need to retrieve data that was saved in error DD Excel Discussion (Misc queries) 2 September 10th 08 01:08 AM
Document Not Saved Error Otivexcel Excel Discussion (Misc queries) 9 March 8th 08 02:18 AM
Error when opening a saved worksheet Kim Excel Worksheet Functions 2 October 3rd 05 05:21 PM
Automation Error and Document not saved Dantz Excel Programming 1 September 22nd 05 09:38 AM


All times are GMT +1. The time now is 11:45 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"