SetElementsAttribute

Sets the specified attribute of the specified elements to the specified value.

Syntax

procedure SetElementsAttribute(aElements: TCSElements; aAttribute: string; aValue: string);

Parameters

  • aElements
  • aAttribute
    • type: string
    • functions: attribute which values have to be set
  • aValue
    • type: string
    • functions: attribute value

Examples

  1. //Loading page google.ru
    LoadURI('google.ru');
    //Get elements
    var elements:=GetElement('input');
    //Set the value of the attribute "class" of all elements equal to "MyClass"
    SetElementsAttribute(elements,'class','MyClass');