I try to change the menu to our company-requirements, some commands should be removed and some commands (e.g. own automation skripts) should be added.
My Problem is that at the first Level of the Menu (Type CommandBarSvr.CommandBarControl) there is no .count or .item
so that i can't get deeper into the Menu-hierarchy to delete or add a control.
Here is my sample code from vb.net:
Dim _dx As CVdApp = Nothing
Dim menu As CommandBarSvr.CommandBar
_dx = CType(GetObject(, "ViewDraw.Application"), CVdApp)
menu = _dx.CommandBars().Item("Sheet Menu Bar")
Dim CommandBar As CommandBarSvr.CommandBarControls = menu.Controls
Dim MainMenu As CommandBarSvr.CommandBarControl
For i As Integer = 1 To CommandBar.Count Step 1
MainMenu = CommandBar.Item(i)
I hope someone could tell me more about the DxDesigner Menu-Automation, in Expedition it works fine with Automation.