How can we use regular expressions for a table in web page,
each cell in table having unique identification, Now I want
to count number of rows in table and enter data in all
cells of the table?



How can we use regular expressions for a table in web page, each cell in table having unique ident..

Answer / ips

intRowCnt=Browser("Google").Page("title:=.*").WebTable(“name:= TTable").RowCount
For r=1 to intRowCnt
‘’ This will loop through each row and tell count of column in each row.
intColCnt=Browser("Google").Page("title:=.*").WebTable(“name:=TTable").ColumnCount(r)
MsgBox intColCnt

for c=1 to intColCnt
Browser("Google").Page("title:=.*").WebTable("WebTable").ChildItem(r,c,"WebList",0).Select strType
or
Browser("Google").Page("title:=.*").WebTable("WebTable").ChildItem(r,c,"WebEdit",index).Set strNumber
Browser("Google").Page("title:=.*").WebTable("WebTable").ChildItem(r,c,"WebCheckBox",index).Set strPreferred

Next
Next

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More QTP Interview Questions

how to create the varibles and how these are connect to qtp? plz tell me

3 Answers  


Inserting a Call to Action is not importing all columns in Datatable of globalsheet. Why?

1 Answers   Crea,


After geting the modules where we generate the script ie in qtp or notpad ?

1 Answers  


In descriptive programming how we know the properties of the objects, if application is not developed and the prototype of the application is also not developed.

1 Answers  


Where we save all scripts in the QTP

5 Answers   Ordain Solutions, Sathya Technologies,


Is it possible to return multiple values from a function..? Then how..?

3 Answers  


Explain how Does Run time data (Parameterization) is handled in QTP?

0 Answers  


what is run-time object property in Object spy in QTP9?

3 Answers  


hi this is srinivasa(from blr) i complited my B.tech(e.c.e) in 2007 im searching job in s/w testing but idont have freshers resume for s/w testing please send some s/w testing resume for me(fresfers resumes only) advns thnks you

2 Answers  


How to open an application through scripting?

11 Answers  


What is clean sweep?

0 Answers  


How we know the qtp has used the smart identification process for identification of the object.

4 Answers   IBM,


Categories