OpenSubMenu()

Syntax

OpenSubMenu(Text$)
Description
Creates an empty sub-menu entry in the current menu. In the Text$, you can use the special '&' character to underline a specific letter :

"&File" will give in reality : <u>F</u>ile

Example:
  If OpenWindow(0, 200, 200, 220, 100, "SubMenu Example")
    If CreateMenu(0, WindowID(0))
      MenuTitle("Project") 
        MenuItem(1, "Open")  
        MenuItem(2, "Close")
        MenuBar()
        OpenSubMenu("Recent files")       ; begin sub-menu
          MenuItem( 3, "C:\Autoexec.bat")
          MenuItem( 4, "D:\Test.txt")
        CloseSubMenu()                    ; end sub-menu
    EndIf
    Repeat : Until WaitWindowEvent()=#PB_Event_CloseWindow
  EndIf

Supported OS

All

<- MenuTitle() - Menu Index - SetMenuItemState() ->