Selects multiple items in a DOM list box. A DomListBox represents all DOM elements that are specified using the <select> tag.
BrowserAPI.bdh
BrowserListBoxMultiSelect( uTestObject : in union, sItemIdentifiers : in string, sTimer : in string optional ): boolean;
Parameter | Description |
---|---|
uTestObject | The XPath locator or the handle to the list box. |
sItemIdentifiers | A comma-separated list of item identifiers. The items can be identified by their name or by their zero-based index. Names can also be combined with an index (for example, you could use blue[2] to identify the second item that has the value of blue). |
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#CwListBox"); // select the first three items BrowserListBoxMultiSelect("//SELECT[@multiple='-1']", "compact, sedan, coupe"); // alternatively you can select items based on their zero-based index (select fourth and fifth item) BrowserListBoxMultiSelect("//SELECT[@multiple='-1']", "[3], [4]"); end TMain;