![]() |
save as
hi,
i have the following: Dim sFileName As Sting sFileName = Application.GetSaveAsFilename I would like to know how to avoid displaying the file saver dialog box that lets you choose the path. I would like to specify the path programatically. Can anyone help with this? thanks in advance, geebee |
save as
Try ActiveWorkbook.SaveAs
geebee noSPAMs wrote: hi, i have the following: Dim sFileName As Sting sFileName = Application.GetSaveAsFilename I would like to know how to avoid displaying the file saver dialog box that lets you choose the path. I would like to specify the path programatically. Can anyone help with this? thanks in advance, geebee |
save as
Geebee,
you can use the SaveAs method of the workbook object. For example Dim sFileName As Sting sFileName="C:\Temp\Book1.xls" ActiveWorkbook.SaveAs sFilename -- Hope that helps. Vergel Adriano "geebee" wrote: hi, i have the following: Dim sFileName As Sting sFileName = Application.GetSaveAsFilename I would like to know how to avoid displaying the file saver dialog box that lets you choose the path. I would like to specify the path programatically. Can anyone help with this? thanks in advance, geebee |
save as
As I understand you want the user to insert the filename, but you want to
define the path. When this is correct try to input the filename in an inputbox as following: Dim sFileName As String Dim sDirName As String sFileName = InputBox("Input Filename", "Input", "") sDirName = "D:\My Documents\" ActiveWorkbook.SaveAs Filename:=sDirName & sFileName, FileFormat _ :=xlNormal, Password:="", WriteResPassword:="", _ ReadOnlyRecommended:= _ False, CreateBackup:=False Regards Klaus "Vergel Adriano" wrote: Geebee, you can use the SaveAs method of the workbook object. For example Dim sFileName As Sting sFileName="C:\Temp\Book1.xls" ActiveWorkbook.SaveAs sFilename -- Hope that helps. Vergel Adriano "geebee" wrote: hi, i have the following: Dim sFileName As Sting sFileName = Application.GetSaveAsFilename I would like to know how to avoid displaying the file saver dialog box that lets you choose the path. I would like to specify the path programatically. Can anyone help with this? thanks in advance, geebee |
All times are GMT +1. The time now is 04:28 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com