How can i count the list box elements in QTP ?using script
plz explain me (Chandana)
Answers were Sorted based on User's Feedback
Answer / pbre
hi you can try this one
browser("SCP").Page("SCP").WebList("ctl00$WebPartManager1
$ResultSu").Click
a = browser("SCP").Page("SCP").WebList("ctl00
$WebPartManager1$ResultSu").GetROProperty("items count")
msgbox a
For i=1 to a
c =browser("SCP").Page("SCP").WebList("ctl00$WebPartManager1
$ResultSu").GetItem(i)
reporter.ReportEvent micPass,c,c
Next
Is This Answer Correct ? | 4 Yes | 4 No |
Answer / rajaputra
url="http://corp.naukri.com/mynaukri/mn_newsmartsearch.php?xz=2_0_5&id="
Systemutil.Run "Iexplore.exe",url
set oDesc= Browser("name:=Mynaukri : naukri.com - India's
No.1 Job Site")
itemcount=oDesc.WebList("name:=qe").GetROProperty("items count")
msgbox "Number of Items in Experience List= "& itemcount
itemcount=oDesc.WebList("name:=qm").GetROProperty("items count")
msgbox "Number of Items in Minimum Salary List= "&itemcount
Is This Answer Correct ? | 3 Yes | 4 No |
Answer / nani
The Following script displays the number of items in the
list box.
intFieldItemsCnt =CInt(GetProperty(Browser
("Browsername").Page("Pagename").Weblist
("weblistname"),"items count"))
msgbox intFieldItemsCnt
Any doughts feel free to make a mail to: nani4urs@gmail.com
Is This Answer Correct ? | 3 Yes | 8 No |
How vl i prioritize the actions when i have 10 actions A1, A2, A3......A10. I want to run action as follows A1,A5,A6 and A10. How i can do it. Thanks in Advance to u.
what is test scheduleling?
How can you close the second opened browser?
Is it possible to change the name of a test object. I mean when we are recording the script for an object (for Ex: Username is a text field which has value "Babu",i am recording that). Then the Name of the object will become "Babu" in object repository. If i want to change "babu" as "xxxxx" .. is it possible to do? Pls help me in this .. if you didn't understand the question, pls let me know.
How to handle Java tree in QTP?
what is framework? which frame work u follow for writting script?
How many add-ins comes by default with qtp?
what happen in object repository(shared)if we call an existing action from an external action ? and what happen in object repository(peraction)if we call an existing action from an external action ?
Explain the concept of how quicktest professional identifies object?
What is the Command used to start the QTP
How to do the scripting. Is there any inbuilt functions in QTP as in QTP-S. Whatz the difference between them? how to handle script issues?
How can we use the "CreateObject("Wscript.Shell")" in QTP and what is the definition and purpose of it?