determinate if pop up menu exists

  • Thread starter Thread starter GUS
  • Start date Start date
G

GUS

I have made a pop up menu which is called by (workbook activate)
How can i determinate whith vba if the pop up menu exists in order not to
create it again when the workbook is reactivate .
p.s. I don't want for some reasons to put the code at (workbook open).
 
Gus,

Here is one way

Set cbcCustomMenu = Application.CommandBars("Worksheet Menu
Bar").Controls("MyMenu")
If cbcCustomMenu Is Nothing Then
'add your menu item
End If

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)
 
Back
Top