:: Home Page            
 Advertise your Business Here     
Browse  |   Placement Papers  |   Company  |   Code Snippets  |   Certifications  |   Visa Questions
Post Question  |   Post Answer  |   My Panel  |   Search  |   Articles  |   Topics  |   ERRORS new
   Refer this Site  Refer This Site to Your Friends  Site Map  Bookmark this Site  Set it as your HomePage  Contact Us     Login  |  Sign Up                      
Categories >> Software >> Testing >> Automation Testing >> QTP


 WinRunner interview questions  WinRunner Interview Questions (496)
 Load Runner interview questions  Load Runner Interview Questions (488)
 QTP interview questions  QTP Interview Questions (3509)
 Test Director interview questions  Test Director Interview Questions (161)
 Rational TestSuite interview questions  Rational TestSuite Interview Questions (106)
 Silk Test interview questions  Silk Test Interview Questions (59)
 Automation Testing AllOther interview questions  Automation Testing AllOther Interview Questions (387)
how can you select random value for every iteration from a
 Question Submitted By :: QTP
I also faced this Question!!     Answer Posted By  
# 1
Dim ListCount

ListCount =
count")'Count the items in the list

ListCount = ListCount-1 'index value starts from 0

Randomize 'initiate random number

RandomValueList = Int(ListCount * Rnd)' convert
listcount as random number in the RandomValueList variable

("#" & RandomValueList) 'Call the RandomValueList variable
appending to index of weblist
Is This Answer Correct ?    4 Yes 1 No
# 2
First get the Items count from the List and Use the
RandomNumber() function to get the random Index value. The
below code will work

ItemsCount = Browser("Browsername").Page("PageTile").WebList
("WebListName").GetROProperty("items count")
("WebListName").Select ("#" & RandomNumber(0,ItemsCount))
Is This Answer Correct ?    6 Yes 7 No
Amarendra Kothuru
# 3
get thetotal items in the list
and use the ' Randamize ' function Rnd()
Is This Answer Correct ?    1 Yes 4 No
# 4
Get the count of elements in the weblist

for i = 0 to count-1

result = randomnumber(i,count-1)

browser("xyz").page("xyz").weblist(" ") .select result

Is This Answer Correct ?    0 Yes 5 No

Other QTP Interview Questions
  Question Asked @ Answers
In QTP for .net application which plug in is used? For Java Application which plug in is used ? AppLabs 2
what is use of the object repository?   4
what is debugging testing?   5
What is time parameter?   1
write vb script code to delete the duplicate values in an array. ADP 3
hello...any one tell me , where can i get company email id.. actually i am searching on testing... in my CV i put 3+ exp.. but all companies are asked company email id.. please provide solution for that... thanx in advance... HDFC 9
Could you please any body help me.for example in web table in the first row and first column there are 3 links like l1,l2,l3 having indexes 0,1,2 but second time links will change their order like l2,l3,l1 and indexes also changed how can we handle this situvation with script....   2
Recovery Manager means..?   4
Hi Friends, How to trap an error message on Web page through QTP. Example:- When I put wrong user id or Password on a web page, I get the error message. So when I add the error object in Reposatory, every time it shows as Login Failed Object exist, eventhough using corret login details. And if I do the same without adding the object it shows as object not found. This might be because while recording QTP takes every new page as _1 _2 _3 and so on. as below. Browser("XXXXX").Page("XXXXX_1"). >>login Browser("XXXXX").Page("XXXXX_2"). >>Inbox Browser("XXXXX").Page("XXXXX_3"). >>Sent Items I used below code. Browser("XXXXX").Page("XXXXX").WebEdit("firstname").Set strFN Browser("XXXXX").Page("XXXXX").WebEdit("lastname").Set strLN Browser("XXXXX").Page("XXXXX").WebEdit("userid").Set strUserID Browser("XXXXX").Page("XXXXX").WebEdit("password").Set strPass Browser("XXXXX").Page("XXXXX").WebButton("Login >").Click If Browser("XXXXX").Page("XXXXX_2").Image ("msg_icon_error").Exist 5 Then Reporter.ReportEvent micFail, "XXXXX", "Login Failed!" ExitRun (It shows login failed ever after login is passed. Else Reporter.ReportEvent micPass, "XXXXX", "Login Successful!" End If Please find out a way for me here, and provide me with the correct code. Thanks in Advance.   1
While recording a login window QTP is identifying only parent window,then how can u identify the child objects. Symphony 2
How can i store runtime value through vb script while using qtp   1
Hi Small doubt . i am working as Contract employee in XYZ comany thrw ABC Consultancy. so. How i write my resume ? In Professional experience Column. plz send urgent   2
For more QTP Interview Questions Click Here 

Copyright Policy  |  Terms of Service  |  Articles  |  Site Map  |  RSS Site Map  |  Contact Us
Copyright 2013  All Rights Reserved.   ::