Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Excel 2003: Customizing Toolbars
Hello, I have a wb with built in commandbars and toolbars customized on the activate wb event and resetted on the deactivate wb event. I'ld like to know if it is possible to prevent the user to disable the macro at the start of the wb and to customize the menus/toolbars. Moreover I can disable a commandbar (for example "Tools") getting it grayed on the worksheet menubar, but I'm not able to hide it completely. I have used this Application.CommandBars("Tools").enabled=False and these Application.CommandBars("Tools").enabled=False Application.CommandBars("Tools").visible=False but with these I'm able to hide only the toolbars (e.g. Standard tb). Emiliano -- eggpap Excel 2003 on Vista HP System - can use VBA ------------------------------------------------------------------------ eggpap's Profile: http://www.thecodecage.com/forumz/member.php?userid=90 View this thread: http://www.thecodecage.com/forumz/sh...ad.php?t=13064 |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Excel 2003: Customizing Toolbars
hi Emiliano, try
Application.Commandbars(1).Controls("Tools").Enabl ed =False CommandBars(1) is also Commandbars("Worksheet Menu Bar") stefan On 20 Jan., 15:47, eggpap wrote: Hello, I have a wb with built in commandbars and toolbars customized on the activate wb event and resetted on the deactivate wb event. I'ld like to know if it is possible to prevent the user to disable the macro at the start of the wb and to customize the menus/toolbars. Moreover I can disable a commandbar (for example "Tools") getting it grayed on the worksheet menubar, but I'm not able to hide it completely. I have used this Application.CommandBars("Tools").enabled=False and these Application.CommandBars("Tools").enabled=False Application.CommandBars("Tools").visible=False but with these I'm able to hide only the toolbars (e.g. Standard tb). Emiliano -- eggpap Excel 2003 on Vista HP System - can use VBA ------------------------------------------------------------------------ eggpap's Profile:http://www.thecodecage.com/forumz/member.php?userid=90 View this thread:http://www.thecodecage.com/forumz/sh...ad.php?t=13064 |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Excel 2003: Customizing Toolbars
thanks Stefan. I have the following code modified according to your tip 'to hide the Standard and Formatting tb correctly performing Application.CommandBars("Standard").Enabled = False Application.CommandBars("Standard").Visible = False Application.CommandBars("Formatting").Enabled = False Application.CommandBars("Formatting").Visible = False 'To hide the CommandBar Help - *I get error 5* Application.CommandBars(1).Controls("Help").Enable d = False Any other tip? Emiliano -- eggpap Excel 2003 on Vista HP System - can use VBA ------------------------------------------------------------------------ eggpap's Profile: http://www.thecodecage.com/forumz/member.php?userid=90 View this thread: http://www.thecodecage.com/forumz/sh...ad.php?t=13064 |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Excel 2003: Customizing Toolbars
hi Emiliano,
do you have a Control with the Caption "Help" or do you mean the "?" (which is the caption for the help in german excel, i`m not sure if it´s the same in english) try Application.CommandBars(1).Controls("?").Enabled = False stefan 'To hide the CommandBar Help - *I get error 5* Application.CommandBars(1).Controls("Help").Enable d = False Any other tip? Emiliano -- |
#5
Posted to microsoft.public.excel.programming
|
|||
|
|||
Excel 2003: Customizing Toolbars
Dear Stefan, I'm an Italian user. The Help control is only one of the controls I need to hide. I get the same error with other controls. My first try was supposing the controls captions was the same I see on the Worksheet Menu Bar but I got "good" results only using the english caption. Emiliano -- eggpap Excel 2003 on Vista HP System - can use VBA ------------------------------------------------------------------------ eggpap's Profile: http://www.thecodecage.com/forumz/member.php?userid=90 View this thread: http://www.thecodecage.com/forumz/sh...ad.php?t=13064 |
#6
Posted to microsoft.public.excel.programming
|
|||
|
|||
Excel 2003: Customizing Toolbars
hi Emiliano,
hmm, do you mean the Help right of the Worksheet Menu Bar, where you can type your question? This will be disabled with Application.CommandBars.DisableAskAQuestionDropdow n = True to disable all Commandbars, you can use For Each cb in Application.CommandBars cb.Enabled =False Next and with the same just True instead of False the visible CommandBars will be restored. stefan On 20 Jan., 20:13, eggpap wrote: Dear Stefan, I'm an Italian user. The Help control is only one of the controls I need to hide. I get the same error with other controls. My first try was supposing the controls captions was the same I see on the Worksheet Menu Bar but I got "good" results only using the english caption. Emiliano |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Excel 2003: Customizing Toolbars | Excel Discussion (Misc queries) | |||
Custom toolbars in Excel 2003 | Excel Programming | |||
Toolbars in Excel 2003 | Excel Discussion (Misc queries) | |||
Customizing ToolBars | Excel Discussion (Misc queries) |