菜单的层级结构
两种菜单形式:
第一种 Toobar菜单条
CommandManager->CommandGroup->CommandItem
commandGroup = this.iCmdMgr.CreateCommandGroup2(this.int_0, this.cmdTitle, this.cmdToolTip, "", 5, true, ref num);
commandGroup.LargeIconList = str + "\\IMG\\ToolbarLarge.bmp";
commandGroup.LargeIconList = str + "\\IMG\\ToolbarLarge.bmp";
commandGroup.LargeMainIcon = str + "\\IMG\\MainIconLarge.bmp";
commandGroup.SmallMainIcon = str + "\\IMG\\MainIconSmall.bmp";
int commandIndex = commandGroup.AddCommandItem2("批量自动出图", -1, "批量自动出图", "批量自动出图", 0, "KYGongNeng11", "EnableAll", 201, 3);
nt commandIndex2 = commandGroup.AddCommandItem2("钣金转CAD", -1, "钣金转DWGDXF", "钣金转CAD", 2, "KYGongNeng7", "EnableAll", 202, 3);
//添加分割线
commandGroup.AddSpacer2(-1, -1);
commandGroup.HasToolbar = true;
commandGroup.HasMenu = true;
commandGroup.Activate();
第二种 CommandTab
-> CommandTab -> CommandTabBox
commandTab = this.iCmdMgr.AddCommandTab(documentType, this.cmdTitle);
CommandTabBox commandTabBox = commandTab.AddCommandTabBox();
commandTabBox.AddCommands(this.cmdIDs, array);
//添加隔断
commandTabBox = commandTab.AddSeparator(commandTabBox, this.cmdIDs[6]);
commandTabBox = commandTab.AddSeparator(commandTabBothis.cmdIDs[26]);
```