Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default Saving a file to a different path

OK I have searched and searched this board and do not see what I need.

I need a very basic macro to save a *.csv file to another Directory.

What I am doing is parsing huge amounts of data and saving the parsed file
to another directory. I got the macro to do what I want, is the automating I
dont get, I eventual want to use a .cmd file to run on the weekend opne each
*.csv file parse the data then save this to another dir.

for those interested the variables:
filename = yyyy-mm-ddwilv.csv ( date is creation date of file from the
import)
Old dir = Q:\TRS_RAW ( network share btw)
new dir = R:\TRS_DATA ( network share)

I have been looking but cant find what I want :/

Thanks in advance.
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 222
Default Saving a file to a different path

You'd be better off using a different variable for filename, say myFile for
example.
myFile = yyyy-mm-ddwilv.csv

Then this will save the file:-

ActiveWorkbook.SaveAs Filename:= new_dir + "\" + myFile, _
FileFormat:=xlCSV, CreateBackup:=False



"SVTman74" wrote:

OK I have searched and searched this board and do not see what I need.

I need a very basic macro to save a *.csv file to another Directory.

What I am doing is parsing huge amounts of data and saving the parsed file
to another directory. I got the macro to do what I want, is the automating I
dont get, I eventual want to use a .cmd file to run on the weekend opne each
*.csv file parse the data then save this to another dir.

for those interested the variables:
filename = yyyy-mm-ddwilv.csv ( date is creation date of file from the
import)
Old dir = Q:\TRS_RAW ( network share btw)
new dir = R:\TRS_DATA ( network share)

I have been looking but cant find what I want :/

Thanks in advance.

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
Formula too long - new file path is shorter than old file path - Excel 2003 Greg J Excel Worksheet Functions 1 November 22nd 06 05:16 PM
Saving excel backup copy - path? ac Excel Discussion (Misc queries) 1 February 4th 05 09:26 PM
Can I change ExCels default save path for saving add-ins ? RandyDtg1 Excel Programming 3 May 16th 04 04:07 PM
Saving using a path HelpMe Excel Programming 2 January 6th 04 05:00 PM
Saving to a Network Path using VBA Mike R Excel Programming 1 August 11th 03 10:34 AM


All times are GMT +1. The time now is 09:22 PM.

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"