Count the number of objects in a web page

How to count the number of objects present in a web page? How to count the number of radio buttons in a web page?

Questions by Sunita2k

Showing Answers 1 - 9 of 9 Answers

METHOD I

Set RadBtn_Desc = Description.Create()
RadBtn_Desc("micclass") = "RadioButton"

Set RadBtn_Coll = Browser(B).Page(P).ChildObjects(RadBtn_Desc)

MsgBox RadBtn_Coll.Count

METHOD II''''''''''I am  not Sure try on ur System

set RadBtn = Browser(B).Page(P).ChildObjects("class := RadioButton")

MsgBox RadBtn.Count

  Was this answer useful?  Yes

Suresh

  • Sep 23rd, 2011
 

set OPage=Browser("Index:=0").Page(":=").childobjects
msgbox OPage.Count

  Was this answer useful?  Yes

nagk24

  • Jan 5th, 2012
 


Set a=Browser("creationtime:=0").page("micclass:=page").ChildObjects
print a.count
For i=0 to a.count-1
print a(i).GetroProperty("text")&" "&a(i).getroproperty("micclass")

Next

  Was this answer useful?  Yes

Give your answer:

If you think the above answer is not correct, Please select a reason and add your answer below.

 

Related Answered Questions

 

Related Open Questions