![]() |
how to disable insert column
How do I disable to insert and delete column in a sheet WITHOUT
protecting the sheet? For example, if I right click on a excel sheet, I see "Insert" & "Delete" menu items, which I would like to grey out or disable it. And I want to achieve this without protecting the sheet. Any help is appreciated. Thanks in advance.. |
how to disable insert column
See
http://www.rondebruin.com/menuid.htm Do not forget the shortcuts -- Regards Ron de Bruin http://www.rondebruin.nl "ndalal" wrote in message oups.com... How do I disable to insert and delete column in a sheet WITHOUT protecting the sheet? For example, if I right click on a excel sheet, I see "Insert" & "Delete" menu items, which I would like to grey out or disable it. And I want to achieve this without protecting the sheet. Any help is appreciated. Thanks in advance.. |
how to disable insert column
Thanks Ron, however I have a couple of problems..
I'm trying to use the following code to disable every "Copy" control in the Menu Bar, Toolbars and right click menus Sub MenuControl_False() ' Excel 2000 - 2003 Dim Ctrl As Office.CommandBarControl For Each Ctrl In Application.CommandBars.FindControls(ID:=19) Ctrl.Enabled = False Next Ctrl End Sub However I need to disable this only for a particular sheet, not all the sheets. How can I achieve this? Also for insert column, I'm only able to disable from menu bar, not from the right click menus. Any clue? Please bear with me as I'm new to excel programming. Thanks.... |
how to disable insert column
Hi ndalal
However I need to disable this only for a particular sheet, not all the sheets. How can I achieve this? See the tips (number 3) http://www.rondebruin.com/menuid.htm#Information Also for insert column, I'm only able to disable from menu bar, not from the right click menus. Any clue? The Id is for insert in the Cell menu is 3181 Application.CommandBars("Cell").FindControl(ID:=31 81).Enabled = False -- Regards Ron de Bruin http://www.rondebruin.nl "ndalal" wrote in message ups.com... Thanks Ron, however I have a couple of problems.. I'm trying to use the following code to disable every "Copy" control in the Menu Bar, Toolbars and right click menus Sub MenuControl_False() ' Excel 2000 - 2003 Dim Ctrl As Office.CommandBarControl For Each Ctrl In Application.CommandBars.FindControls(ID:=19) Ctrl.Enabled = False Next Ctrl End Sub However I need to disable this only for a particular sheet, not all the sheets. How can I achieve this? Also for insert column, I'm only able to disable from menu bar, not from the right click menus. Any clue? Please bear with me as I'm new to excel programming. Thanks.... |
All times are GMT +1. The time now is 05:30 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com