SetDisabled Method (HTMLCONTROL)


10.9, PLBCMP GUI Only

 

The SetDisabled method changes the disabled boolean attribute in a HTML element contained in a HTMLCONTROL object. The method sets the disabled attribute in the HTML element that has an id attribute that matches the id parameter. This method uses the following format:

 

[label]

{object}.SetDisabled

[GIVING {return}] USING [*Id=]{id}:

 

 

[*Value=]{value}[,[*Flags=]{flags}]

 

Where:

label

Optional. A Program Execution Label.

object

Required. A HTMLCONTROL that is accessed.

return

Optional. A Numeric Variable that always returns zero.

Id

Required. A Character String Variable or literal that contains the HTML element id attribute.

value

Required. A Character String Variable or literal that has the value string applied to disabled attribute.

flags

Optional. A Numeric Variable or decimal value that specifies a bit mask value that controls the behavior of this method.

Flags Affected: OVER, ZERO

Note the following:

  1. This method changes the disabled boolean value in a HTML element contained in a HTMLCONTROL object.

  2. The ZERO flag is always set TRUE.

  3. The OVER flag is always set FALSE.

  4. The {id} is a value that determines the HTML element used for data changes. The {id} string is matched against the id attribute of the HTML element.

  5. The valid values for the {value} parameter are the strings False or True.

  6. The {flags} parameter is a bitmask value that forces specialized behaviors for the execution of this method.

  7. The {return} value will always be zero.

Example:

 

For a HTMLCONTROL that contains a HTML element as follows:

 

<input type='checkbox' id='MyCheck' checked>

 

This PL/B SetDisabled method changes the disabled boolean value using the following instruction:

 

     HtmlControl.SetDisabled Using "MyCheck","True"

 

In this instruction, the HTML disabled attribute is turned on in the HTML element with the id attribute of "MyCheck".

 

 

See Also: HTMLCONTROL Method Syntax



PL/B Language Reference