Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Save text file as Excel 2007 with cell as filename
I have a delimited file which has been reformatted and need to save it as
Excel 2007workbook (.xlsx?) I am using the contents of a cell as the filename. It is saving, but when I try and re-open it it says the file extension is not recognized. If I save as .xls it has the old 2003 icon on the file. Also, I don't want the file to prompt the user to re-save when they try and close. Here is what I have: Range("A1").Select ActiveWorkbook.SaveAs Filename:=Range("Z1").Value & ".xlsx" End Sub Thanks, Kelly |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Save text file as Excel 2007 with cell as filename
Make sure you specify the correct fileformat, too.
See help for .saveas for more details. KellyinCali wrote: I have a delimited file which has been reformatted and need to save it as Excel 2007workbook (.xlsx?) I am using the contents of a cell as the filename. It is saving, but when I try and re-open it it says the file extension is not recognized. If I save as .xls it has the old 2003 icon on the file. Also, I don't want the file to prompt the user to re-save when they try and close. Here is what I have: Range("A1").Select ActiveWorkbook.SaveAs Filename:=Range("Z1").Value & ".xlsx" End Sub Thanks, Kelly -- Dave Peterson |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Save text file with value from Excel Cell stamped with date and time | Excel Programming | |||
Excel wants to save an open file to another filename in VBA script | Excel Programming | |||
Filename has Url in file-save dialog when saving exported Excel do | Excel Programming | |||
Save file, refer filename to cell and change directory | Excel Programming | |||
Save excel file with filename = cell text | Excel Programming |