Table of Contents
Enumerations #
Name | Values |
---|---|
SearchTypes | Contains |
BeginsWith | |
SortDirections | Ascending |
Descending | |
States | Unvalidated |
Valid | |
Invalid |
Constants #
This class exposes no constants.
Events #
Name | Parameters | Return Type | Description |
---|---|---|---|
DoubleClick | None | None | Fires when the user double-clicks the field in MultiSelect. |
GotFocus | None | None | Raised when the control receives focus. |
HeightChanged | oldHeight as Integer | None | Raised when the height of the control has changed. Typically used with the AdaptiveHeight property set to True. |
LostFocus | None | None | Raised when the control loses focus. |
PopupButtonPressed | None | None | Raised when the user clicks the button embedded in the popup menu. |
PopupHidden | None | None | Raised when the user has hidden the popup menu. |
PopupShown | None | None | Raised when the user has shown the popup menu. |
SelectionAdded | theItem as GraffitiPopupMenuItem | None | Fires when an item is selected in MultiSelect. |
SelectionChanged | theItem as GraffitiPopupMenuItem | None | This event is fired when one or more items in the popupmenu are selected. |
SelectionCleared | None | None | This event is raised when the user has cleared the selected items. |
SelectionRemoved | theItem as GraffitiPopupMenuItem | None | Fires when an items is deselected in MultiSelect. |
Methods #
Name | Parameters | Return Type | Description |
---|---|---|---|
AddItem | ItemText as String | None | Adds a new item to the list of items in the popupmenu. |
AddItem | NewItem as GraffitiPopupMenuItem | None | Adds a new item to list of items in the popupmenu. |
AddItems | items() as GraffitiPopupMenuItem | None | Adds the specified array of items to the popupmenu in a single operation. |
AddItemAt | index as Integer item as GraffitiPopupMenuItem | None | Adds the specified item at the provided index. |
ClosePopup | None | None | Closes the popup, if it is shown. |
DeselectAll | DoLockUpdate as Boolean = False | None | Clears the current selection. When DoLockUpdate is True, regardless of the value of the LockUpdate property, execution is deferred. |
ItemAt | index as Integer | GraffitiPopupMenuItem | Returns the item as the specified index within the internal items array. |
ItemFromTag | theTag as Variant | GraffitiPopupMenuItem | Returns the item whose tag matches theTag . |
ItemFromText | theText as String | GraffitiPopupMenuItem | Returns the item whose text matches theText . |
ItemIndex | item as GraffitiPopupMenuItem | Integer | Returned the integer index of the provided item within the internal item array. |
LastItemIndex | None | Integer | Returns the index of the last row of items added to the PopupMenu. |
OpenPopup() | None | None | Opens the popup. |
RemoveAllItems | None | None | Removes all items from the popupmenu and updates the display. |
RemoveItem | ItemIndex as Integer | None | Removes the specified item from the list of items in the popupmenu. |
RemoveItem | ItemText as String | None | |
SelectedItems | None | GraffitiPopupMenuItem() | Returns the currently selected item(s). |
SelectedItemsIndexes | None | Integer() | Returns the indexes of the currently selected item(s). |
Properties #
Name | Type | Default Value | Description |
---|---|---|---|
AdaptiveHeight | Boolean | False | When True, the control will resize vertically based on the height of the selected items and raise the HeightChanged event. |
AllowAdd | Boolean | False | When MultipleSelect = False, AllowAdd being True will cause GraffitiPopupMenu to behave more like a combobox, allowing custom item input. |
AllowClear | Boolean | False | When True, a clear button is displayed in the UI that allows users to clear their previous selection. |
DropdownStyle | GraffitiStyle | Nil | GraffitiStyle used to apply CSS to the dropdown menu. |
IsPopupVisible | Boolean | False | Determines the visible state of the popup menu. |
LocaleCustom | Boolean | False | When True, will use the other Locale properties in place of the default text. |
LocaleInputTooShort | String | “” | Text to display when the user hasn’t entered enough text in the search field. |
LocaleInputTooLong | String | “” | Text to display when the user has entered too many characters in the search field. |
LocaleNoMatches | String | “No Matches Found” | Text displayed when the user’s search returns an empty set of results. |
LocaleSelectionTooLarge | String | “” | Text to display when the user has selected too many items. |
LockUpdate | Boolean | False | When True, code execution to manipulate and update items in the browser is deferred until set to False. |
MaxSelecteditems | Integer | 5 | Limits the possible amount of selected items. |
MinimumInputLength | Integer | 3 | Minimum number of characters user must enter before a search will be performed. If 0, all items will be shown by default. |
MultipleSelect | Boolean | True | Determines whether the popupmenu will support selection of multiple items. |
PlaceholderSearchText | String | “” | Text to display in the search box for instances where MultipleSelect = False. |
PlaceholderText | String | “Please select an option” | The text to display when there are no items selected. |
PopupButtonText | String | “” | When populated, a button will be displayed on the popup that, upon click, will raise the PopupButtonPressed event. |
PopupButtonIndicator | WebUIControl.Indicators | WebUIControls.Indicators.Default | Bootstrap style to apply to the popup button. |
PopupButtonStyle | GraffitiStyle | Nil | GraffitiStyle to apply to the popup button. |
ReadOnly | Boolean | False | If True, the user cannot change the value of the control. |
ReserveIconSpace | Boolean | False | If True, all items will have whitespace on the left of their text whether they have an icon or not. |
SearchThreshold | Integer | 10 | The number of characters required to trigger the search algorithm. Set to -1 to remove the search field. |
SearchType | GraffitiPopupMenu.SearchTypes | Contains | Method used when performing a search from the search box for GraffitiPopupMenuItems. |
SortDirection | SortDirections | SortDirections.Ascending | Direction to sort items. |
SortItems | Boolean | False | When True, items will be sorted within the dropdown menu. |
State | States | Unvalidated | Alters the display to convey a validation state. |
StyleTag | GraffitiStyle | Nil | Style applied to tags when MultipleSelect = True. |
Text | String | Empty | Current text value of the control. Only applicable when MultipleSelect = False and AllowAdd = True. |
Notes #
The PopupShown event should not be used to modify the contents of the control. This is too late for changes to be sent to the client browser and will cause the dropdown to hidden again as part of the update.
Examples #
There are currently no examples for this class.