ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Office 2007 Shortcut Menus (https://www.excelbanter.com/excel-programming/425962-office-2007-shortcut-menus.html)

XP

Office 2007 Shortcut Menus
 
Working in Office 2007 with Windows XP;

I use the following code to enable and disable the shortcut menus
in Excel:

Private Function ShortCutMenusEnable(argEnable As Boolean)
'true to enable all right-click/shortcut menus; false to disable:
Dim cbCommandbar As CommandBar
For Each cbCommandbar In Application.CommandBars
cbCommandbar.Enabled = argEnable
Next
End Function

This function works, BUT now I can't keep the shortcut menus working. Every
time I open a new workbook, the shortcuts are disabled and I have to run the
above code again to enable them!

There must be a switch or something else I'm missing in 2007? Could someone
please clue me in?

Thanks for your assistance.


XP

Office 2007 Shortcut Menus
 

FYI,

Discovered that a file called Excel12.xlb on my "C" drive was corrupted.
Trashed this file and now all is good...

Hope this may help someone, some time...


"XP" wrote:

Working in Office 2007 with Windows XP;

I use the following code to enable and disable the shortcut menus
in Excel:

Private Function ShortCutMenusEnable(argEnable As Boolean)
'true to enable all right-click/shortcut menus; false to disable:
Dim cbCommandbar As CommandBar
For Each cbCommandbar In Application.CommandBars
cbCommandbar.Enabled = argEnable
Next
End Function

This function works, BUT now I can't keep the shortcut menus working. Every
time I open a new workbook, the shortcuts are disabled and I have to run the
above code again to enable them!

There must be a switch or something else I'm missing in 2007? Could someone
please clue me in?

Thanks for your assistance.



All times are GMT +1. The time now is 06:16 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com