IBindingCheckBox.CaptionDefined

Syntax

CaptionDefined: Boolean;

Description

The CaptionDefined property determines whether the TEXT parameter is present in binding string.

Comments

If the CaptionDefined property is set to True, the binding string describing the value editor will contain the TEXT parameter. The value of this parameter is determined by the Caption property.

Example

Sub CheckBoxBindingInfo(SourceBinding: String);
Var
    BM: IBindingManager;
    Binding: IBindingValue;
    CheckBoxBinding: IBindingCheckBox;
Begin
    BM := New BindingManager.Create;
    Binding := BM.CreateByValue(SourceBinding);
    If Binding.UI = "CheckBox" Then
        CheckBoxBinding := Binding As IBindingCheckBox;
        
//Check if the ALIGN parameter is present
        If CheckBoxBinding.AlignDefined Then
            Debug.WriteLine(
"ALIGN: " + CheckBoxBinding.Align.ToString);
        
End If;

        //Check if the TEXT parameter is present
        If CheckBoxBinding.CaptionDefined Then
            Debug.WriteLine("TEXT: " + CheckBoxBinding.Caption);
        End If;
        //Check if there is the VALUE parameter
        If CheckBoxBinding.ValueDefined Then
            Debug.WriteLine("VALUE: " + CheckBoxBinding.Value.ToString);
        End If;
    End If;
End Sub CheckBoxBindingInfo;

This function checks the binding string passed as the SourceBinding input parameter. If the binding string corresponds to the editor as the radio button, values of parameters will be displayed in the development console.

See also:

IBindingCheckBox