Hey Guys,
as you can see, by reading the topic, i have Problems with the context-menus under Visio2010. With Visio 2003 and 2007 everything works fine and i never needed to change my code. But since 2010 the customized context menu isnt included in the context menu when i right-click on a blank Page. When i right-click on a shape, it doesnt matter on which one, it works on alll of them, the context menu looks like i want it to.
Is there any way to solve this Problem? When i start from zero and programm it via fluentUI like the Ribbon it wont change a thing, would it?
Here the import parts of the code:
Set DrawingDoc = ActiveDocument
Set vsoUIObject = DrawingDoc.Application.BuiltInMenus
Set vsoMenuSetsObj = vsoUIObject.MenuSets
Set vsoMenuSetObj = vsoMenuSetsObj.ItemAtID(visUIObjSetCntx_DrawObjSel)
Set vsoMenusObj = vsoMenuSetObj.Menus
Set vsoMenuObj = vsoMenusObj(0)
Set vsoMenuItemsObj = vsoMenuObj.MenuItems
Call Modul_Toolbar.create_Pagemenu(vsoMenuItemsObj)
Example for what happens in create_Pagemenu:
Set vsoMenuItemObj = vsoMenuItemsObj.AddAt(0)
vsoMenuItemObj.Caption = Shape_UEbersicht_D
vsoMenuItemObj.AddOnName = "ThisDocument.statistik"
vsoMenuItemObj.TypeSpecific1 = visIconIXDRAWINGEXPLORER
I hope this is enough for you to understand the way i create my context-menu.
i appreciate any help,
bye,
Max