Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 75
Default Disabling Toolbar

I am trying to disable the 'Insert' and 'View' of the worksheet menu bar with
the following codes -

Application.CommandBars("Insert").Enabled = false
Application.CommandBars("View").Enabled = false

but is having a problem; only 'View' is disabled but 'Insert' is not. Is
it because
"Insert" cannot be disabled in this manner? Is so, how can I disable
'Insert'.

Thank you.


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 182
Default Disabling Toolbar

Hi Ang,

Try this one :
CommandBars(1).Controls("insert").Enabled = False

Because Insert is a control of Worksheet Menu Bar is index=1
so I use 1
--

Regards,

Halim


"Francis Ang" wrote:

I am trying to disable the 'Insert' and 'View' of the worksheet menu bar with
the following codes -

Application.CommandBars("Insert").Enabled = false
Application.CommandBars("View").Enabled = false

but is having a problem; only 'View' is disabled but 'Insert' is not. Is
it because
"Insert" cannot be disabled in this manner? Is so, how can I disable
'Insert'.

Thank you.


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 75
Default Disabling Toolbar

Thanks alot Halim. Appreciate your help very much.

"Halim" wrote:

Hi Ang,

Try this one :
CommandBars(1).Controls("insert").Enabled = False

Because Insert is a control of Worksheet Menu Bar is index=1
so I use 1
--

Regards,

Halim


"Francis Ang" wrote:

I am trying to disable the 'Insert' and 'View' of the worksheet menu bar with
the following codes -

Application.CommandBars("Insert").Enabled = false
Application.CommandBars("View").Enabled = false

but is having a problem; only 'View' is disabled but 'Insert' is not. Is
it because
"Insert" cannot be disabled in this manner? Is so, how can I disable
'Insert'.

Thank you.


  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,123
Default Disabling Toolbar

Hi

Better to use Id numbers instead of the name
No problem if you run it in a non English version

See
http://www.rondebruin.nl/menuid.htm

--
Regards Ron de Bruin
http://www.rondebruin.nl



"Francis Ang" wrote in message ...
Thanks alot Halim. Appreciate your help very much.

"Halim" wrote:

Hi Ang,

Try this one :
CommandBars(1).Controls("insert").Enabled = False

Because Insert is a control of Worksheet Menu Bar is index=1
so I use 1
--

Regards,

Halim


"Francis Ang" wrote:

I am trying to disable the 'Insert' and 'View' of the worksheet menu bar with
the following codes -

Application.CommandBars("Insert").Enabled = false
Application.CommandBars("View").Enabled = false

but is having a problem; only 'View' is disabled but 'Insert' is not. Is
it because
"Insert" cannot be disabled in this manner? Is so, how can I disable
'Insert'.

Thank you.




  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 75
Default Disabling Toolbar

Hi Ron,

Thank you for the execellent tip. Appreciate it very much.

"Ron de Bruin" wrote:

Hi

Better to use Id numbers instead of the name
No problem if you run it in a non English version

See
http://www.rondebruin.nl/menuid.htm

--
Regards Ron de Bruin
http://www.rondebruin.nl



"Francis Ang" wrote in message ...
Thanks alot Halim. Appreciate your help very much.

"Halim" wrote:

Hi Ang,

Try this one :
CommandBars(1).Controls("insert").Enabled = False

Because Insert is a control of Worksheet Menu Bar is index=1
so I use 1
--

Regards,

Halim


"Francis Ang" wrote:

I am trying to disable the 'Insert' and 'View' of the worksheet menu bar with
the following codes -

Application.CommandBars("Insert").Enabled = false
Application.CommandBars("View").Enabled = false

but is having a problem; only 'View' is disabled but 'Insert' is not. Is
it because
"Insert" cannot be disabled in this manner? Is so, how can I disable
'Insert'.

Thank you.





Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Adjusting toolbar size, restore toolbar Josh M Excel Discussion (Misc queries) 1 January 18th 06 06:17 PM
Disabling Toolbar Buttons with no open Workbook Paul Martin Excel Programming 1 October 28th 03 10:27 PM
Disabling Print on TOOLBAR Dan Gesshel Excel Programming 5 October 23rd 03 10:12 PM
Disabling Toolbar buttons and CommandBar items Jim[_20_] Excel Programming 2 August 14th 03 02:33 PM
Disabling toolbar customization kb Excel Programming 0 July 29th 03 08:33 PM


All times are GMT +1. The time now is 08:54 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"