Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Leave the listbox empty at design stage and include code similar to as follows:

Dim oDlg As Object

DialogLibraries.LoadLibrary("Standard")

oDlg = CreateUnoDialog(DialogLibraries.Standard.MyFormName)

Dim oCtl As Object

oCtl = oDlg.getControl("ListBox1")

oCtl.addItem("Item-x",0)

oCtl.addItem("item-y",1)

oCtl.addItem("Other",2)

To find the item selected use code similar to:

Dim sPmt As String

oCtl = oDlg.getControl("ListBox1")

sPmt = oCtl.getSelectedItem()