MultiListBox

Displays a list of items in a multiple-selection list box dialog.

Syntax

Rhino.MultiListBox (arrItems [, strMessage [, strTitle [, strDefault [, arrPos]]]])

Rhino.MultiListBox (arrItems [, strMessage [, strTitle [, arrDefaults [, arrPos]]]])

Parameters

arrItems

Required.  Array.  A zero-based, one-dimensional array of string items.

strMessage

Optional.  String.  A prompt or message.

strTitle

Optional.  String.  A dialog box title.

strDefault

Optional.  String.  The selected item in the list.

arrDefault

Optional.  Array.  The selected items in the list.

arrPos

Optional.  Array.  A 2-D screen point that identifies the upper left corner of the dialog's initial position.

Returns

Array

A zero-based, one-dimensional array containing the selected item if successful.

Null

If not successful, or on error.

Example

Dim arrLayers, arrResults, i

arrLayers = Rhino.LayerNames

If IsArray(arrLayers) Then

arrResults = Rhino.MultiListBox(arrLayers, "Layers to lock")

If IsArray(arrResults) Then

For i = 0 To UBound(arrResults)

Rhino.LayerMode arrResults(i), 2

Next

End If

End If

 

multilistbox.jpg

 

Also See

CheckListBox

ComboListBox

ListBox

PropertyListBox