For any corporate training requirements Please mail To sudhakar@qtpsudhakar.com
New Schedule in MindQ Systems, Madhapur By SUDHAKAR
Course Name Date Time Duration Type Branch
Selenium+Appium+Katalon 9th June 2018 9.30 AM - 11 AM IST 35 Days ClassRoom + Online Mind Q Madhapur

A book "Cracking the QTP interview" authored by Sudhakar.Read More. Buy From FlipKart

Monday, May 4, 2009

ListBox Object

The default method for List box is "Select".
Browser("Mercury Tours").Page("Find Flights").WebList("depart").Select "London"
Can we do anything more with ListBox?
1. Selecting more items in a list
2. Get all items from a list
'Selecting more items in a list
Browser("Mercury Tours").Page("Find Flights").WebList("depart").Select "London"
Browser("Mercury Tours").Page("Find Flights").WebList("depart"). ExtendSelect "Paris"
'Select is to select single item in a list box
'ExtendSelect is to select more than one item after selecting an item in list box using select method
'Get all items from a list
Dim iCount
Dim iIndex
iCount=Browser("Countrywide").Page("Countrywide").WebList("LoanType").GetROProperty("items count")
For iIndex=1 to iCount
msgbox Browser("Countrywide").Page("Countrywide").WebList("LoanType").GetItem(iIndex)

1 comment :

  1. How to Remove the Duplicate value in List box list using vb script.. plz tel