Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Save an Excel file with a new name

Status
Not open for further replies.

PJFry

Technical User
Feb 6, 2005
93
US
I am new to Excel VB and I want to write a routine that will save the current Excel file in same directory as the original, using the same name as the current file with '_External' appended to the end.

The current file is :
C:\Rpt\Richards_June07
The new file will save as
C:\Rpt\Richards_June07_External

The external file would overwrite anything out there.

I code quite a bit in Access, but the Excel objects are still very new to me.

Ideas?
Thanks in Advance!
PJ
 




Hi,

Turn on your macro recorder in Excel and then File > SaveAs...

Please post VBA questions in Forum707.

Skip,
[sub]
[glasses] To be safe on the [red]FOURTH[/red],
Don't take a [red]FIFTH[/red] on the [red]THIRD[/red]
Or you might not come [red]FORTH[/red] on the [red]FIFTH[/red]
[red][highlight blue]FORTH[/highlight][/red][white][highlight red]WITH[/highlight][/white] [tongue][/sub]
 
Thanks for the re-direct! I will post it in the correct forum.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top