### MenuBar add Separator dynamically

Example Subroutine for adding a separator menu item dynamically (requires the JavaObject library).
' Example call: AddMenuSeparator(MenuBar1, 0) where 0 is the first menu item
`Sub AddMenuSeparator(mb As MenuBar, menuidx As Int)
Dim joSepMi As JavaObject
joSepMi.InitializeNewInstance("javafx.scene.control.SeparatorMenuItem", Null)
Dim mnu As Menu = mb.Menus.Get(menuidx)
mnu.MenuItems.Add(joSepMi)
End Sub`

Changed: , Category: Menu, File: T6C220M1612.htm, ID: 1612