Hi, When I click on a hyperlink a secondary pop-window will
open. In that pop-up window there will be 'N' number of
records arranged in with paging option in datagrid table.
Each rows contains two columns, one is text and the other
is a radio button. I will pass the first column value and
based in it the tool have to select the corresponding radio
button in that row. Please someone help me how to handle
this as am new to QTP.

Answer Posted / badri

'To find no of rows in webtable
rc=Browser(" ").Page(" ").WebTable(" ").RowCount
msgbox "No. of Rows: "&rc

'Give the text
b=inputbox("Enter the text u want to search....")
For i= 2 to rc
getdata=Browser(" ").Page(" ").WebTable("
").GetCellData(i,1)
msgbox getdata
If (ucase(trim(b)))=(ucase(trim(getdata))) Then
' msgbox "Both are Equal"
set obj= Browser(" ").Page(" ").WebTable("
").ChildItem(i,1,"webradiobutton",0)
obj.click
Exit for
'Go to next page
browser(" ").page(" ").webtable(" ").Link(" ")
End If
Next


' If wrong correct me

Is This Answer Correct ?    4 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

we use a file extension .properties why is it used and where do we use it plz help me out with detailed explanation and navigation of how to use on the QTP 8.2?

1859


Are Shared ORs read-only?

855


If an application name changes frequently i.e while recording it has the name, in this case, how do qtp handles?

794


Is it possible to call from one action to another action in qtp?

796


How to associate shared object repository to test in qtp?

731


What is action?

781


one screen page,that contains file , browse , update and cancel buttons.when we browse a file it should get update otherwise it should go to previous page.write negative test case for that.

1709


What is the expert view?

764


describe some problems that u had with automating testing tool?

1595


how can you do retesting (datadriven test) using notepad amd by using functions NOTE u should not use datatable methods

1634


am not having intrest in coding lang like c c++ java etc can i choose Testing tools as my carrier and please suggest me which tool is good (suitable for me)

1499


Differentiate the type of test cases which can be automated and which cannot be automated?

789


How may types of defects identify application or your currently working application?pls give me answer..

1731


How many types of recording facility are available in quicktest professional (qtp)?

816


What do you to script when objects are removed from application?

822