Re: SaveAs command doesn't save extension
- From: "Norman Jones" <normanjones@xxxxxxxxxxxxxxxxxxx>
- Date: Sun, 8 Apr 2007 14:27:24 +0100
Hi Stewart,
Try:
NewBook.SaveAs Filename:=fName & "xls", _
FileFormat:=xlWorkbookNormal
---
Regards,
Norman
"stewart" <smccallister@xxxxxxxxx> wrote in message
news:1176037647.873368.192150@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
I am trying to pull a SaveAs dialog box from a VB command that will
prompt the user to save their work. The problem is when the user
types in the filename it does not save as an excel file. The user
would have to type the extension themselves and that is not feasible
for this application. Below is the code I got from VB Help. Is there
another way?
sub savenew()
Set NewBook = Workbooks.Add
Do
fName = Application.GetSaveAsFilename
Loop Until fName <> False
NewBook.SaveAs Filename:=fName
end sub
.
- Follow-Ups:
- Re: SaveAs command doesn't save extension
- From: Norman Jones
- Re: SaveAs command doesn't save extension
- References:
- SaveAs command doesn't save extension
- From: stewart
- SaveAs command doesn't save extension
- Prev by Date: Re: How do I keep Hidden Columns / Rows from being Unhidden / Refe
- Next by Date: Re: Write VB6 code to be used with VBA
- Previous by thread: SaveAs command doesn't save extension
- Next by thread: Re: SaveAs command doesn't save extension
- Index(es):
Relevant Pages
|