DhSelectBox | +--DhListBoxpublic class DhListBox
Represents a list box control. This class manages adding, removing, and selecting items, as well as scrolling. The list box control can be used within a form (see DhSection) to transmit data.
Constructors
Name | Description |
---|---|
DhListBox( ) | Creates a DhListBox control. |
DhListBox( int nRows, int selectionStyle) | Creates a DhListBox object. |
Methods
Name | Description |
---|---|
getAlignment() | Retrieves the current alignment value of the list box. |
getSelectionStyle() | Returns the current selection style of the list box. |
getVisibleRows( ) | Retrieves the number of currently visible rows. |
setAlignment( int nAlignment ) | Sets the alignment of the list box relative to the text around it. |
setSelectionStyle(int value) | Determines how many items at a time can be selected in the list box. |
setVisibleRows( int nRows ) | Sets the number of visible rows in the list box. |
Creates a DhListBox control. This default constructor creates a list box control with two visible rows, which allows only single selections.
Creates a DhListBox object.
Retrieves the current alignment value of the list box. Returns one of the alignment constant values in DhAlignEnum.
Returns the selection style. Possible values are:
Returns the current selection style of the list box.
Returns the number of rows.
Retrieves the number of currently visible rows.
Sets the alignment of the list box relative to the text around it.
Note that The SelectionStyle.ONE and SelectionStyle.MULTI_SIMPLE are not valid for DhListBox.
Determines how many items at a time can be selected in the list box.
Sets the number of visible rows in the list box.
IllegalArgumentException thrown if nRow is less than 2.