Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Multiple records
#1
Solved: 11 Years, 4 Months ago
Hi,
I am very new to QTP and I am given the following problem. I have a list of invoices in the application and I have to make sure the every invoice I click, should display some details. I have thought of looping the script but sometimes that doesn't work. Can anyone suggest me an idea on how i can solve this problem? Thanks
Reply
#2
Solved: 11 Years, 4 Months ago
For example, I have a manual generated script here
Code:
Browser("UWindsor").Page("ENG").Frame("_sweview_2").Image("Select record").Click
Browser("UWindsor").Page("ENG”).Frame("_sweview_3").Link("Line Items").Click
Browser("UWindsor").Page("ENG").Frame("_swescrnbar").Link("Invoices").Click
'Browser("UWindsor").Page("ENG").Frame("_sweview_4").Image("Select record").Click
'Browser("UWindsor").Page("ENG").Frame("_sweview_5").Link("Line Items").Click
'Browser("UWindsor").Page("ENG").Frame("_swescrnbar").Link("Invoices").Click
'Browser("UWindsor").Page("ENG").Frame("_sweview_6").Image("Select record").Click
'Browser("UWindsor").Page("ENG").Frame("_sweview_7").Link("Line Items").Click
'Browser("UWindsor").Page("ENG").Frame("_swescrnbar").Link("Invoices").Click
--------------

I have written a looping code

Code:
Browser("UWindsor").Page("ENG").Frame("_swescrnbar").Link("Invoices").Click

Browser("UWindsor").Page("ENG").Frame("_sweview").Link("Line Items").Click
Browser("UWindsor").Page("ENG").Frame("_swescrnbar").Link("Invoices").Click

i=2
While i<=10
    Browser("UWindsor").Page("ENG").Frame("_sweview_"&i).Image("Select record").Click    
    i = i + 2
Browser("UWindsor").Page("ENG").Frame("_sweview").Link("Line Items").Click
Browser("UWindsor").Page("ENG").Frame("_swescrnbar").Link("Invoices").Click
Wend
Browser("UWindsor").Page("ENG").Sync
-----
When I run this looping code, I get the error message that the "_sweview_8" frame object repository was not found in the object repository. Can anybody suggest what i should do? Thanks
Reply
#3
Solved: 11 Years, 4 Months ago
Hi

If it can recognise sweview2,4,6 and why not 8.do u have a frame called sweview_8 in your OR ?!!!!!if not you need to include that

regards
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  How to delete the cookies (1000 records) akhandesh 1 2,741 09-03-2014, 09:57 AM
Last Post: vinod123
  problem with reading records from DB2 table sqadri 2 3,302 06-23-2012, 12:33 AM
Last Post: sqadri
  How to compare records in data table with records in web table? mohit 0 2,796 12-17-2011, 10:11 AM
Last Post: mohit
  Delete records using QTP pramod7385 9 5,569 02-26-2010, 04:35 PM
Last Post: Saket
  QTP 9.5 Does not record all steps and records some steps backwards jsdaubs 1 2,444 07-30-2008, 05:02 PM
Last Post: siri

Forum Jump:


Users browsing this thread: 2 Guest(s)