IBindingCheckBox.Caption

Fore Syntax

Caption: String;

Fore.NET Syntax

Caption: String;

Description

The Caption property determines the TEXT parameter value in binding string.

Comments

The TEXT parameter determines radio button caption.

The Caption property is available if the CaptionDefined property is set to True. If the Caption property is changed, the CaptionDefined property is automatically set to True.

Fore Example

Function CreateCheckBoxBidning(Caption: String): String;
Var
    BM: IBindingManager;
    CheckBoxBinding: IBindingCheckBox;
Begin
    BM := 
New BindingManager.Create;
    CheckBoxBinding := BM.CreateByUi(
"CheckBox"As IBindingCheckBox;
    CheckBoxBinding.Align := CheckAlignment.Right;
    CheckBoxBinding.Caption := Caption;
    CheckBoxBinding.Value := 
True;
    
Return CheckBoxBinding.AsString;
End Function CreateCheckBoxBidning;

This function generates binding string to use value editor as a radio button. A text, which will be displayed next to radio button, is sent as the Caption input parameter. The checkbox will be located to the right relative to text. Checkbox state - selected.

Fore.NET Example

The requirements and result of the Fore.NET example execution match with those in the Fore example.

Imports Prognoz.Platform.Interop.ForeSystem;

Function CreateCheckBoxBidning(Caption: String): String;
Var
    BM: BindingManager = New BindingManagerClass();
    CheckBoxBinding: IBindingCheckBox;
Begin
    CheckBoxBinding := BM.CreateByUi("CheckBox"As IBindingCheckBox;
    CheckBoxBinding.Align := CheckAlignment.chRight;
    CheckBoxBinding.Caption := Caption;

    CheckBoxBinding.Value := True;
    Return CheckBoxBinding.AsString;
End Function;

See also:

IBindingCheckBox