[Overview][Constants][Types][Classes][Procedures and functions][Index] |
[Properties (by Name)] [Methods (by Name)] [Events (by Name)]
TDBRadioGroup - a data-aware version of TRadioGroup, providing a series of mutually exclusive buttons to select an entry to insert into a database field
Source position: dbctrls.pp line 520
type TDBRadioGroup = class(TCustomRadioGroup) end; |
||
protected |
||
procedure Change; virtual; |
|
Change - calls the OnChange event handler if it is assigned |
procedure Notification(); override; |
|
|
procedure DataChange(); |
|
DataChange - updates the current Value to reflect a change inthe data |
procedure UpdateData(); |
|
UpdateData - places the current Value into the data |
property DataLink: TFieldDataLink; [r] |
|
DataLink - the field data link to be used for the data |
function GetButtonValue(); |
|
GetButtonValue - returns the string value of the button associated with the specified index |
procedure UpdateRadioButtonStates; override; |
|
UpdateRadioButtonStates - performs the inheited method and ensures that any updates are also reflected via the data link, if it is active and in an Editing state |
public |
||
constructor Create(); override; |
|
Create - constructor for TDBRadioGroup: calls inherited Create then forms datalinks and actions |
destructor Destroy; override; |
|
Destroy - destructor for TDBRadioGroup: frees links and items, then calls inherited Destroy |
procedure EditingDone; override; |
|
EditingDone - updates the record through the datalink, then calls inherited EditingDone |
function ExecuteAction(); override; |
||
function UpdateAction(); override; |
||
property Field: TField; [r] |
|
The DataSet Field relevant to the data being selected |
property ItemIndex: Integer; |
|
The Index value in the list of Items (a stringlist with the names of the selections for radio buttons) |
property Value: string; [rw] |
|
The selected value (as indicated by ItemIndex) |
published |
||
|
Specifies the placement of the control inside its Parent. |
|
|
The set of anchor definitions for this control. |
|
property BiDiMode: TBiDiMode; |
||
property BorderSpacing: TControlBorderSpacing; |
|
Determines the inner and outer border spacing for this control. |
|
The text describing the control to the user. |
|
property Columns: Integer; |
|
Columns - the number of columns in which the Items (radio buttons) are to be arranges |
property DataField: string; [rw] |
|
The name (as a string) of the Field whose data are linked to the control |
property DataSource: TDataSource; [rw] |
|
The DataSource from which relevant Field data are to be linked - usually the result of a database query |
property DragCursor: TCursor; |
|
The cursor shape shown while the control is dragged. |
|
Allows the user to drag the control. |
|
property Enabled: Boolean; |
|
Determines whether the control reacts on mouse or keyboard input. |
property Items: TStrings; [w] |
|
Items - a string list containing the captions for the radio boxes |
property OnChange: TNotifyEvent; [rw] |
|
Event Handler for any change in the radiogroup selection |
property OnChangeBounds: TNotifyEvent; |
|
Event handler for a change of the Bounds of the control. |
property OnClick: TNotifyEvent; |
|
Notification handler for 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 OnEndDrag: TEndDragEvent; |
|
Notification handler for the end of a dragging operation. |
property OnMouseDown: TMouseEvent; |
|
Event handler for mouse button going down. |
property OnMouseEnter: TNotifyEvent; |
||
property OnMouseLeave: TNotifyEvent; |
||
property OnMouseMove: TMouseMoveEvent; |
|
Event handler for mouse movement within the control. |
property OnMouseUp: TMouseEvent; |
|
Event handler for mouse button going up. |
property OnMouseWheel: TMouseWheelEvent; |
||
property OnMouseWheelDown: TMouseWheelUpDownEvent; |
||
property OnMouseWheelUp: TMouseWheelUpDownEvent; |
||
property OnResize: TNotifyEvent; |
|
Notification handler for a resize of the control. |
property OnStartDrag: TStartDragEvent; |
|
Event handler for the start of a dragging operation. |
property ParentBiDiMode: Boolean; |
||
property ReadOnly: Boolean; [rw] |
|
ReadOnly - if True, data can only be read, not written or modified. (Doesn't really make sense for a RadioGroup!) |
|
Determines the sequence of controls, reachable when the user presses the Tab key. |
|
property TabStop: Boolean; |
||
property Values: TStrings; [rw] |
|
The values of the strings in Items |
property Visible: Boolean; |
|
Allows to show or hide the control, and all of its children. |
|
TDBRadioGroup - a data-aware version of TRadioGroup, providing a series of mutually exclusive buttons to select an entry to insert into a database field |
|
| | ||
|
TCustomRadioGroup: the base type for TRadioGroup |
|
| | ||
|
The base class for TGroupBox, TRadioGroup and TCheckGroup. |
|
| | ||
|
The base class for controls which can contain other (child) controls. |
|
| | ||
|
The base class for visible controls. |
|
| | ||
|
The base class for LCL components associated with widgets. |
|
| | ||
TComponent |
||
? | ||
TObject |
The properties of TDBRadioGroup are similar to those of TRadioGroup (and TCustomRadioGroup). Access is obtained to members of the group by selecting (in the Object Inspector) the ellipsis (...) next to the entry Items, and then editing the stringlist.
At runtime, selecting one of the radiobuttons makes the corresponding ItemIndex available to the programmer, and the corresponding string Item gets selected and appears as the string value for the record in that field.
|
HowToUseDataAwareControls - Hints for accessing databases |
lazarus-ccr.sourceforge.net |