jasgot
New Member
- Joined
- Jul 16, 2002
- Messages
- 30
- Office Version
- 365
- 2019
- 2016
- 2013
- 2010
- Platform
- Windows
I have a macro that prints after doing some work for me.
I would like to disable the print options from the menu and tool bars so the user must click my button in the sheet.
I've tried these two peices of code, neither addresses the user pressing <ctrl>-P and both leave the print option removed from excel for other workbooks even if I re enable them in an Auto_Close macro.
Application.CommandBars(1).FindControl(ID:=109, recursive:=True).Enabled = False
'Application.CommandBars(1).FindControl(ID:=2521, recursive:=True).Enabled = False
'Application.CommandBars("File").Controls("Print...").Enabled = False
'Application.CommandBars("Standard").Controls(6).Enabled = False
Can someone shed some light on a better way to force users to use *my* print macro?
I would like to disable the print options from the menu and tool bars so the user must click my button in the sheet.
I've tried these two peices of code, neither addresses the user pressing <ctrl>-P and both leave the print option removed from excel for other workbooks even if I re enable them in an Auto_Close macro.
Application.CommandBars(1).FindControl(ID:=109, recursive:=True).Enabled = False
'Application.CommandBars(1).FindControl(ID:=2521, recursive:=True).Enabled = False
'Application.CommandBars("File").Controls("Print...").Enabled = False
'Application.CommandBars("Standard").Controls(6).Enabled = False
Can someone shed some light on a better way to force users to use *my* print macro?