This function applies to <INPUT TYPE="RADIO"> HTML elements. It selects the radio button identified by the locator or handle respectively.
BrowserAPI.bdh
BrowserRadioButtonSelect( uTestObject : in union, sTimer : in string optional ): boolean;
Parameter | Description |
---|---|
uTestObject | The XPath locator or the handle to the DOM element. |
sTimer | Optional: Name of the timer used for page measurements. If this parameter is omitted, no measurements are performed. |
true if successful
false otherwise
benchmark SilkPerformerRecorder use "Kernel.bdh" use "BrowserAPI.bdh" dcluser user VUser transactions TInit : begin; TMain : 1; var dclrand dcltrans transaction TInit begin end TInit; transaction TMain begin BrowserStart(BROWSER_MODE_DEFAULT, 800, 600); BrowserNavigate("http://demo.borland.com/TestSite/gwt/Showcase.html#CwRadioButton"); // check the first radio button BrowserRadioButtonSelect("//INPUT[@name='color'][1]"); // chek the fourth radio button BrowserRadioButtonSelect("//INPUT[@name='color'][4]"); end TMain;