[Overview][Constants][Types][Classes][Procedures and functions][Index] |
[Properties (by Name)] [Methods (by Name)] [Events (by Name)]
Implements a data-aware listbox control with database lookup capabilities.
Source position: dbctrls.pp line 454
type TDBLookupListBox = class(TCustomDBListBox) |
||
protected |
||
procedure DataChange(); override; |
|
Performs actions needed when a new DataField value is selected using the lookup dataset. |
procedure DoSelectionChange(); override; |
|
Performs actions needed when the selected item in the listbox is changed. |
procedure InitializeWnd; override; |
|
Initializes the window handle for the control. |
procedure DestroyWnd; override; |
|
Frees the window handle and updates the address used for the Items in the controls. |
procedure KeyDown(); override; |
|
Applies the specified virtual key code to the control. |
procedure Loaded; override; |
|
Performs actions needed when the control has loaded using the LCL streaming mechanism. |
procedure UpdateData(); override; |
|
Updates the data in the lookup dataset for the control. |
function IsUnbound; |
|
Indicates if the control is being used in the "unbound" mode. |
public |
||
constructor Create(); override; |
|
Constructor for the class instance. |
property KeyValue: Variant; [rw] |
|
Accesses the value for the KeyField in the lookup dataset. |
published |
||
|
Specifies the placement of the control on its Parent control. |
|
|
The set of anchor definitions for this control. |
|
property BiDiMode: TBiDiMode; |
|
Customization (of text controls) in bidirectional reading environments. |
property BorderSpacing: TControlBorderSpacing; |
|
Determines the inner and outer border spacing for this control. |
property BorderStyle: TBorderStyle; |
|
Indicates the border style displayed around the control. |
|
The background color of the control. |
|
property Constraints: TSizeConstraints; |
|
Contains the minimum and maximum Width and Height for the control. |
property DataField: string; |
|
Name for the field in the linked dataset used in the control. |
property DataSource: TDataSource; |
|
Provides access to the linked dataset for the control. |
property DoubleBuffered: Boolean; |
|
Allows to reduce flicker in the painting of the control. |
property DragCursor: TCursor; |
|
The cursor shape shown while the control is dragged. |
|
The operation when the control is dragged - Drag or Dock. |
|
|
Allows the user to drag the control. |
|
property Enabled: Boolean; |
|
Determines whether the control reacts on mouse or keyboard input. |
|
The font to be used for text display in this control. |
|
property KeyField: string; [rw] |
|
Field name in the lookup dataset with the value for the control. |
property ListField: string; [rw] |
|
Field name with the descriptive value displayed in the listbox. |
property ListFieldIndex: Integer; [rw] |
|
Ordinal position of the field in the lookup dataset with the descriptive value displayed in the control. |
property ListSource: TDataSource; [rw] |
|
Datasource with the lookup dataset for the control. |
property LookupCache: Boolean; [rw] |
|
Indicates if caching is enabled for fields in the lookup dataset. |
property NullValueKey: TShortCut; [rw] |
|
Keyboard shortcut used to assign the empty key value to the control. |
property EmptyValue: string; [rw] |
|
Value used as the empty field value in the DataField for the control. |
property DisplayEmpty: string; [rw] |
|
Descriptive text displayed for the EmptyValue in the control. |
property OnClick: TNotifyEvent; |
|
Notification handler for mouse clicks. |
property OnContextPopup: TContextPopupEvent; |
|
Invoked when a context-sensitive pop-up menu is requested. |
property OnDblClick: TNotifyEvent; |
|
Event Handler for double mouse clicks. |
property OnDragDrop: TDragDropEvent; |
|
This handler determines the action on an drop onto this control, in a drag-drop operation. |
property OnDragOver: TDragOverEvent; |
|
Event handler for a control being dragged over this control. |
property OnEditingDone: TNotifyEvent; |
|
Event handler signalled when editing is done. |
property OnEndDrag: TEndDragEvent; |
|
Notification handler for the end of a drag operation. |
property OnEnter: TNotifyEvent; |
|
Handler for control receiving the focus. |
property OnExit: TNotifyEvent; |
|
Handler for control loosing the focus; This is a good place for checking the finished user input. |
property OnKeyPress: TKeyPressEvent; |
|
Handler for a character entered by the user. |
|
Handler for keyboard key pressed. |
|
|
Event handler signalled when a key up event has occurred for the control. |
|
property OnMouseDown: TMouseEvent; |
|
Event handler signalled when a mouse down event is handled for the control. |
property OnMouseEnter: TNotifyEvent; |
|
Event handler signalled when the mouse pointer has entered the control. |
property OnMouseLeave: TNotifyEvent; |
|
Event handler signalled when the mouse pointer has left the control. |
property OnMouseMove: TMouseMoveEvent; |
|
Event handler for mouse movement within the control. |
property OnMouseUp: TMouseEvent; |
|
Event handler signalled when a mouse up event is handled for the control. |
property OnMouseWheel: TMouseWheelEvent; |
|
Event handler for mouse wheel turned. |
property OnMouseWheelDown: TMouseWheelUpDownEvent; |
|
Event handler for downward movement of mouse wheel. |
property OnMouseWheelUp: TMouseWheelUpDownEvent; |
|
Event handler for upward movement of the mouse wheel. |
property OnResize: TNotifyEvent; |
|
Notification handler for a resize of the control. |
property OnStartDrag: TStartDragEvent; |
|
Event handler for the start of a dragging operation. |
property OnUTF8KeyPress: TUTF8KeyPressEvent; |
|
Handler for a character entered by the user. |
property Options: TListBoxOptions; |
|
Contains options enabled for the list box control. |
property ParentBiDiMode: Boolean; |
|
Indicates whether the BiDiMode settings in the Parent control are used. |
property ParentDoubleBuffered: Boolean; |
|
Value for the DoubleBuffered property in a Parent control. |
property ParentShowHint: Boolean; |
|
If True, the value of ShowHint for the control will be the same as the one from the Parent. Default is True. |
property PopupMenu: TPopupMenu; |
|
A context-sensitive menu that pops up when the right mouse button is clicked over this control. |
property ReadOnly: Boolean; |
|
Indicates if the linked dataset for the control cannot be modified. |
property ScrollListDataset: Boolean; [rw] |
|
Indicates if the look-up data set is scrolled for a new value in the control. |
property ShowHint: Boolean; |
|
Enables Hint display for the control. |
property Sorted: Boolean; |
|
Determines whether the list entries are sorted in alphanumeric order. |
|
Indicates the navigation order for the control when the user presses the Tab or Shift+Tab key. |
|
property TabStop: Boolean; |
|
Allows the user to navigate to / from the control by pressing the Tab or Shift+Tab keys. |
property TopIndex: Integer; |
|
Index of the first visible (or top-most) item. |
property Visible: Boolean; |
|
Allows the control, and all of its children, to be displayed or hidden. |
end; |
|
Implements a data-aware listbox control with database lookup capabilities. |
|
| | ||
|
Specifies a data-aware listbox control. |
|
| | ||
|
The base class for TListBox. |
|
| | ||
|
Implements a windowed control which can contain other child controls. |
|
| | ||
|
The base class for visible controls. |
|
| | ||
|
The base class for LCL components which have an associated widget. |
|
| | ||
TComponent |
||
? | ||
TObject |
TDBLookupListBox is a TCustomDBListBox descendant which implements a data-aware listbox with database lookup capabilities.
TDBLookupListBox allows selection of a value from a list of items, and stores the value to a field in a linked dataset. The database lookup feature allows a separate dataset to be used which contains the values for the items available in the control. Individual fields can be specified for both the stored value and the the associated display value. Internally, it uses a TDBLookup component to enable the database lookup feature.
In addition, the control can be used in an unbound mode where either the DataSource or the DataField is not defined for the control. This allows the lookup dataset to synchronized when the current selection in the control is changed, but prevents the selected value from being stored in the linked dataset.
Use ListSource to provide access to the lookup dataset used in the control. Use ListField or ListFieldIndex to specify the field name or ordinal position in the lookup dataset displayed in the listbox. Use KeyField to specify the field name in the lookup dataset with the value stored in the DataField for the control. Use KeyValue to read or write the value for the KeyField in the lookup dataset.
|
Indicates if the control is being used in the "unbound" mode. |
|
|
Provides access to the linked dataset for the control. |
|
|
Name for the field in the linked dataset used in the control. |
|
|
Datasource with the lookup dataset for the control. |
|
|
Field name with the descriptive value displayed in the listbox. |
|
|
Ordinal position of the field in the lookup dataset with the descriptive value displayed in the control. |
|
|
Field name in the lookup dataset with the value for the control. |
|
|
Accesses the value for the KeyField in the lookup dataset. |
|
|
TDBLookup - used as source of data by TDBLookupListBox or TDBLookupComboBox, to find data from a lookup table. |