LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 80
Default saving new file name

Douvid,

You need to write some VB code in a macro for this. In
short, your code should:

1.get the old name file before you save under the new name:
oldname = activeworkbook.path & "/" & _
activeworkbook.name
2.save under the new name
activeworkbook.saveas "TheNewFilename.xls"
same folder, or full path for different folder). The new
file name will most likely be a variable whose value is
read from the spreadsheet, I guess (in that case omit the
quotes).
3. delete original file
kill oldname

HTH,
Nikos
-----Original Message-----
Hi ,
I need to save an open file under a new name by replacing

the old one.
The problem is that the new name is generated by the

content of the file, I mean that the file is open.
Does someone has a good idea.

cheers,
Douvid

.

 
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
Saving Excel 2007 file in 2003 creates very large file Jon Pearce Excel Discussion (Misc queries) 2 July 16th 09 07:20 PM
Confused here Prevent Saving File - but allow ONLY File SAVEAS Met JMay Excel Discussion (Misc queries) 2 June 17th 07 04:37 PM
Saving worksheet in new file with date AND cell value as file name michaelberrier Excel Discussion (Misc queries) 4 May 26th 06 08:05 PM
How do I stop Excel 2000 from saving file history from file that . Cathy Excel Discussion (Misc queries) 0 March 29th 05 03:27 PM
Saving a file(new) using the multiple cell contents as a file name Dave Peterson[_3_] Excel Programming 1 August 1st 03 01:40 PM


All times are GMT +1. The time now is 10:30 AM.

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

About Us

"It's about Microsoft Excel"