Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
I try it again. Howto. Proposed Filename and path different by the default with VBA
Hi all,
I submit again my issue because I have not managed to make myself understood yesterday. I have a macro that is lauched by MsAccess and among the other things, it opens an Excel workbook formatted by the template ExcelTemp.xlt I programmatically open the workbook with. The workbook consists of a list of costs/prices and totals. When the macro ends, the Excel sheet needs to remain Open and Active for the user to check/complete the workbook and save it,manually. So, file saving is not made by the macro automaticallybut by the user. Now, Excel proposes a default filename (in the titlebar) as the filename of the template plus 1 ( template = ExcelTemp.xlt - proposed filename: ExcelTemp1.xls) and the destination directory, the same of the template. Now, I would like to be able to let Excel propose a filename and path to save the file to different by these: they should both be the same of the MsAccess database (but filename with extension xls, of course). How can I programmatically command Excel to "propose" different filename and path than the default ones? My goalis to let the user csimply click on save and the file is already saved in the right directory with the right name. Thank you. Fabian |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
I try it again. Howto. Proposed Filename and path different by the default with VBA
Don't believe that is possible.
-- Regards, Tom Ogilvy "Fabian" wrote in message oups.com... Hi all, I submit again my issue because I have not managed to make myself understood yesterday. I have a macro that is lauched by MsAccess and among the other things, it opens an Excel workbook formatted by the template ExcelTemp.xlt I programmatically open the workbook with. The workbook consists of a list of costs/prices and totals. When the macro ends, the Excel sheet needs to remain Open and Active for the user to check/complete the workbook and save it,manually. So, file saving is not made by the macro automaticallybut by the user. Now, Excel proposes a default filename (in the titlebar) as the filename of the template plus 1 ( template = ExcelTemp.xlt - proposed filename: ExcelTemp1.xls) and the destination directory, the same of the template. Now, I would like to be able to let Excel propose a filename and path to save the file to different by these: they should both be the same of the MsAccess database (but filename with extension xls, of course). How can I programmatically command Excel to "propose" different filename and path than the default ones? My goalis to let the user csimply click on save and the file is already saved in the right directory with the right name. Thank you. Fabian |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
I try it again. Howto. Proposed Filename and path different by the default with VBA
Fabian,
In the _BeforeSave event, show your own dialog with your desired defaults. Save the file. Cancel=true So you only do this the first time, it is probably good to check the ..Path="". NickHK "Fabian" wrote in message oups.com... Hi all, I submit again my issue because I have not managed to make myself understood yesterday. I have a macro that is lauched by MsAccess and among the other things, it opens an Excel workbook formatted by the template ExcelTemp.xlt I programmatically open the workbook with. The workbook consists of a list of costs/prices and totals. When the macro ends, the Excel sheet needs to remain Open and Active for the user to check/complete the workbook and save it,manually. So, file saving is not made by the macro automaticallybut by the user. Now, Excel proposes a default filename (in the titlebar) as the filename of the template plus 1 ( template = ExcelTemp.xlt - proposed filename: ExcelTemp1.xls) and the destination directory, the same of the template. Now, I would like to be able to let Excel propose a filename and path to save the file to different by these: they should both be the same of the MsAccess database (but filename with extension xls, of course). How can I programmatically command Excel to "propose" different filename and path than the default ones? My goalis to let the user csimply click on save and the file is already saved in the right directory with the right name. Thank you. Fabian |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
http://CannotDeleteFile.net - Cannot Delete File? Try Long Path ToolFilename is too long? Computer Complaining Your Filename Is Too Long? TheLong Path Tool Can Help While most people can go about their businessblissfully unaware of the Windo | Excel Discussion (Misc queries) | |||
showing path and filename | Excel Worksheet Functions | |||
How do i display the Filename without the path? | Excel Discussion (Misc queries) | |||
Choosing default path/filename in Excel with VBA | Excel Programming | |||
Filename and path | Excel Programming |