Software Developer's Kit - ChemDraw

Send comments on this topic
MenuBars Collection
See Also  Members 

Description

Member of ChemDraw Control.

For a list of all members defined for this collection, see MenuBars Members.

ChemDraw MenuBars Collection contains all of the MenuBar objects in the document.   

Remarks

MenuBars is a collection containing all of the MenuBar objects in the ChemDraw document.

Example

Private Sub cmdApplication_click()
   'Declares variables 
    Dim myMenu As ChemDrawControl11Ctl.Menu
    Dim myMenus As ChemDrawControl11Ctl.Menus
    Dim myMenuBar As ChemDrawControl11Ctl.MenuBar
    Dim myMenuBars As ChemDrawControl11Ctl.MenuBars
    Dim myMenuItem As ChemDrawControl11Ctl.MenuItem
    Dim myMenuItems As ChemDrawControl11Ctl.MenuItems   
   'Sets menu bars  
    Set myMenuBars  = ctlChemDraw.Application.MenuBars
   'MENU BARS properties
    Set myMenuBar = ctlChemDraw.Application.MenuBars.Item(1)   
    Text1.Text = myMenuBars.Application
    Text2.Text = "Menu Bars: " & myMenuBars.Count
End Sub

See Also