Hi martindwilson;
Thanks, unfortunately that's not what I need. When I'm working in 2007, I want the file I'm working in to save as a 2007 file. I just don't want my macro file to be saved as 2007 file.
Hi martindwilson;
Thanks, unfortunately that's not what I need. When I'm working in 2007, I want the file I'm working in to save as a 2007 file. I just don't want my macro file to be saved as 2007 file.
or![]()
Private Sub Workbook_BeforeClose(Cancel As Boolean) ThisWorkbook.SaveAs ThisWorkbook.FullName End Sub
or![]()
Private Sub Workbook_BeforeClose(Cancel As Boolean) ThisWorkbook.SaveAs ThisWorkbook.FullName, xlExcel8 End Sub
![]()
Private Sub Workbook_BeforeClose(Cancel As Boolean) ThisWorkbook.SaveAsCopy ThisWorkbook.FullName, xlExcel8 End Sub
Last edited by snb; 08-08-2010 at 05:45 PM.
Under Excel Options,Advanced, General, there an option to open all file in:
So maybe you can save your macro workbook in a separate folder and enter it there. If you indicate XLSTART it will open All files in that folder which may not be what you want.
Ben Van Johnson
protonLeah;
I want the macro file to be accessed by all instances of Excel whether 2002 or 2007. I just don't want to have it saved in a format that 2002 can't access.
snb;
I'm saving that as a last resort. I was hoping to avoid a macro to do it.
I'm curious. Have you tried this? Wouldn't the "SaveAs" method crash because the filename already exists? I assumed that I would have to SaveAs a filename in a different folder then another SaveAs to put it back into XLSTART.
I added the SaveAsCopy option.
The method is SaveCopyAs
Entia non sunt multiplicanda sine necessitate
snb;
I understand what you're doing. I'm just questioning whether it will work the way you have done it. I'm under the impression that SaveAs and SaveCopyAs cannot save themselves on to themselves. I admit that I haven't tried it yet, but I assume that Excel cannot save a file onto an open file. The fact that the names already exists would trigger "Do you want to Overwrite" question, but then because the file is in use by somebody, that it wouldn't let you save.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks