getProperties

returns an object with the available configuration attributes of the control

object getProperties(string id);

Parameters

idstringoptional, the id of a radio button

Returns

objectan object either with the available attributes of the control and their values, or with the available attributes of the radio button and their values

Example

var form = new dhx.Form("form_container", { 
    rows: [
        {
            id: "radiogroup",
            type: "radioGroup",
            required: true,
            label: "Radio Group",
            labelWidth: 140,
            labelPosition: "left",
            helpMessage: " Help information",
            value: "1",
            options: {
                rows: [
                    {
                        id: "1,"
                        type: "radioButton",
                        text: "Select 1",
                        value: "1",
                    },
                    {
                        id: "2",
                        type: "radioButton",
                        text: "Select 2",
                        value: "2"
                    },
                ]
            }
        }
     ]
});
 
form.getItem("radiogroup").getProperties();
 
// -> the returned object for the RadioGroup control
{
    errorMessage: "",
    height: "content",
    helpMessage: " Help information",
    hiddenLabel: false,
    label: "Radio Group",
    labelPosition: "left",
    labelWidth: 140,
    options: {rows: Array(2), full: false},
    padding: 0,
    preMessage: "",
    required: true,
    successMessage: "",
    width: "content"
}
 
form.getItem("radiogroup").getProperties("1");
 
// -> the returned object for the specified radio button of the control
{
    height: "content"
    padding: 0
    text: "Select 1"
    width: "content"
}

Details

The returned object of the RadioGroup control can contain the following configuration attributes:

RadioButton properties

Change log

added in v7.0

Back to top