Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
changing "save as" on menu
I want to change the "Save As" on the menu form to go directly to a different
form. I do not want it to update the original. I have already disabled other forms of "save" with the code below: Private Sub workbook_open() 'With CommandBars("File") With Me.Application.CommandBars("File") ..Controls(4).Enabled = False 'Save Button End With Me.Application.CommandBars("standard").Controls("S ave").Enabled = False End Sub Private Sub Workbook_BeforeClose(Cancel As Boolean) With Me.Application.CommandBars("File") .Controls(4).Enabled = True End With Me.Application.CommandBars("Standard").Controls("S ave").Enabled = True Me.Application.Dialogs(xlDialogSaveAs).Show "C:\New_Expense_Report.xls" End Sub Any help would be appreciated! Thanks in Advance, Elena |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
changing "save as" on menu
Try this
Sub test() Application.CommandBars("Worksheet Menu Bar").FindControl _ (ID:=748, Recursive:=True).OnAction = "yourmacro" End Sub Sub yourmacro() MsgBox "" End Sub Use this to reset Sub test2() Application.CommandBars("Worksheet Menu Bar").FindControl _ (ID:=748, Recursive:=True).OnAction = "" End Sub -- Regards Ron de Bruin http://www.rondebruin.nl "Elena" wrote in message ... I want to change the "Save As" on the menu form to go directly to a different form. I do not want it to update the original. I have already disabled other forms of "save" with the code below: Private Sub workbook_open() 'With CommandBars("File") With Me.Application.CommandBars("File") .Controls(4).Enabled = False 'Save Button End With Me.Application.CommandBars("standard").Controls("S ave").Enabled = False End Sub Private Sub Workbook_BeforeClose(Cancel As Boolean) With Me.Application.CommandBars("File") .Controls(4).Enabled = True End With Me.Application.CommandBars("Standard").Controls("S ave").Enabled = True Me.Application.Dialogs(xlDialogSaveAs).Show "C:\New_Expense_Report.xls" End Sub Any help would be appreciated! Thanks in Advance, Elena |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
"CELL("FILENAME") NOT UPDATE AFTER "SAVE AS" ACTION | Excel Discussion (Misc queries) | |||
Lost "File Menu" - now it's "Edit / View / Insert.." but no "F | Excel Discussion (Misc queries) | |||
"Save" and "Save As" options greyed out - "Save as Webpage" option | Excel Discussion (Misc queries) | |||
Changing "returned" values from "0" to "blank" | Excel Worksheet Functions | |||
save and restore "Workbook Menu Bar" & "Cell" menus | Excel Programming |