Menus in Excel 2007
I commented out On Error Resume Next and ran it in Excel 2007. It ran fine
for me and took all the programmed actions. Then I changed all the False's
to True and restored everything. So I don't think the problem is
necessarily xl2007 itself. Are you using smart menus? I don't, but if you
do, they might be problematic if the items are not visible - I can't say for
sure because I haven't tested it.
--
Regards,
Tom Ogilvy
"Geoff" wrote:
Not sure if this is the correct group but...
This proc in E 2003 no longer does what is required in E 2007 and only gets
by because of 'On Error Resume Next':
Sub DisableMenus()
'''Disable 'Sheet' menus
On Error Resume Next
'''Insert Worksheet
Application.CommandBars("Worksheet Menu Bar").FindControl(ID:=852,
Recursive:=True).Enabled = False
With Application.CommandBars("Edit")
.Controls("Delete Sheet").Enabled = False
.Controls("Move or Copy Sheet...").Enabled = False
End With
Application.CommandBars("Ply").Enabled = False
On Error GoTo 0
End Sub
Does anyone have an idea how to convert?
Geoff
|