![]() |
ToolBars
Forum, Hope you can help, I have joined today as well so be nice :cool: I am creating a worksheet that will require all of the toolbars to be removed on the worksheet open, and all the toolbars returned when the worksheet closes. I have seen this done, a worksheet was opened and there were no toolbars including the menu one. Could someone help me out. Regards, Bach -- bach ------------------------------------------------------------------------ bach's Profile: http://www.excelforum.com/member.php...o&userid=26134 View this thread: http://www.excelforum.com/showthread...hreadid=394613 |
You need to use VB code, here is a method courtesy of Ron De Bruin. If
you're unfamiliar with code, post back, Regards, Alan. Private Sub Workbook_Activate () Dim bar As CommandBar For Each bar In Application.CommandBars bar.Enabled = False Next End Sub Private Sub Workbook_Deactivate () Dim bar As CommandBar For Each bar In Application.CommandBars bar.Enabled = True Next End Sub "bach" wrote in message ... Forum, Hope you can help, I have joined today as well so be nice :cool: I am creating a worksheet that will require all of the toolbars to be removed on the worksheet open, and all the toolbars returned when the worksheet closes. I have seen this done, a worksheet was opened and there were no toolbars including the menu one. Could someone help me out. Regards, Bach -- bach ------------------------------------------------------------------------ bach's Profile: http://www.excelforum.com/member.php...o&userid=26134 View this thread: http://www.excelforum.com/showthread...hreadid=394613 |
Alan, Thanks for reply to my post, I have used the code and the only issue I have is that the formula bar remains is this supose to happen.?? Bach -- bach ------------------------------------------------------------------------ bach's Profile: http://www.excelforum.com/member.php...o&userid=26134 View this thread: http://www.excelforum.com/showthread...hreadid=394613 |
It is because it is not a commandbar. You can fix it though
Dim mFormulaBar Sub RemoveFormulaBar() mFormulaBar = Application.DisplayFormulaBar Application.DisplayFormulaBar = False End Sub Sub RestoreFormulaBar() Application.DisplayFormulaBar = mFormulaBar End Sub -- HTH Bob Phillips "bach" wrote in message ... Alan, Thanks for reply to my post, I have used the code and the only issue I have is that the formula bar remains is this supose to happen.?? Bach -- bach ------------------------------------------------------------------------ bach's Profile: http://www.excelforum.com/member.php...o&userid=26134 View this thread: http://www.excelforum.com/showthread...hreadid=394613 |
Bob, Thanks for replying to my problem, it works a charge. Regards Bach -- bach ------------------------------------------------------------------------ bach's Profile: http://www.excelforum.com/member.php...o&userid=26134 View this thread: http://www.excelforum.com/showthread...hreadid=394613 |
.... a charge?
-- HTH Bob Phillips "bach" wrote in message ... Bob, Thanks for replying to my problem, it works a charge. Regards Bach -- bach ------------------------------------------------------------------------ bach's Profile: http://www.excelforum.com/member.php...o&userid=26134 View this thread: http://www.excelforum.com/showthread...hreadid=394613 |
All times are GMT +1. The time now is 08:49 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com