Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Unwanted iterations When I am running Excel Sheet
#1
Solved: 11 Years, 4 Months ago
Hi,
I have Script like this,
Code:
DataTable.Importsheet"C:\QA\Zip1.xls",1,Global
wait(2)
If Browser("name:=MLSListings.com").Page("title:=MLSListings.com").WebEdit("name:=cityzip").Exist Then
Browser("name:=MLSListings.com").Page("title:=MLSListings.com").WebEdit("name:=cityzip").Object.focus
Browser("name:=MLSListings.com").Page("title:=MLSListings.com").WebEdit("name:=cityzip").Set DataTable("Zip", dtGlobalSheet)
wait(10)
Browser("name:=MLSListings.com").Page("title:=MLSListings.com").WebCheckBox("name:=RES").Set DataTable("RES", dtGlobalSheet)
Browser("name:=MLSListings.com").Page("title:=MLSListings.com").WebCheckBox("name:=CONDO").Set DataTable("CONDO", dtGlobalSheet)
Browser("name:=MLSListings.com").Page("title:=MLSListings.com").WebCheckBox("name:=LOTSLAND").Set DataTable("LOTSLAND", dtGlobalSheet)
Browser("name:=MLSListings.com").Page("title:=MLSListings.com").WebCheckBox("name:=MULT").Set DataTable("MULTI", dtGlobalSheet)
Browser("name:=MLSListings.com").Page("title:=MLSListings.com").WebCheckBox("name:=RENTAL").Set DataTable("RENTAL", dtGlobalSheet)
I have recored with the following values(now it is in Global Datasheet)
Zip RES CONDO LOTSLAND MULTI RENTAL COMM
95126 ON ON ON ON ON ON

After that I Parameterized( using Global data table).

-----------------------------------------------------------
My Excel Sheet Has following values

Row1 Zip RES CONDO LOTSLAND MULTI RENTAL COMM
Row2 94087 ON ON ON ON ON ON ON
Row3 94086 ON ON OFF ON OFF OFF ON

-----------------------------------------------------------
When I am Running I am Able to see the Excel sheet values in the Global data Sheet.It Looks like this

Row1 94087 ON ON ON ON ON ON ON
Row2 94086 ON ON OFF ON OFF OFF ON

------------------------------------------------------------
I used RUN ALL ROWS(In actions AND FILE-SETTINGS RUN)

The first iteration Iteration1(Row1 )Works correctly.It takes the 94087 values-correct

When it comes to the Iteraion2(Row2)It goes
Action1 Iteration1(row1).ItTakes the 94086 Value-Correct
Action2 Iteration2(row2)-I don't need this IterationIt search the page and it is giving error.
How can I avoid the Action2 Iteration2(row2)?
I tried with Row1-2 -It also gives the same problem.
I tried with one iteration(it works forist row,but i need to run the 2row also)
Result page is attached
Any Help?
Thanks for your time.
Thank you.
Uma


Attached Files
.doc   iteration.doc (Size: 96 KB / Downloads: 71)
Reply
#2
Solved: 11 Years, 4 Months ago
Hi,
I Gave Local parameter instead of Global.It is working.
Thx
Uma
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Repeat iterations Until New Value Is Seen in Column1 shayk1985 1 1,752 07-05-2018, 05:52 PM
Last Post: Ankur
  UFT Datatable iterations Studymode 2 3,803 12-12-2017, 11:10 PM
Last Post: Studymode
  Reading data from excel sheet serenediva 1 9,625 03-03-2017, 10:07 AM
Last Post: vinod123
  QTP-Re-executing script after completion of all iterations JwalantBhatt0602 1 2,703 03-24-2016, 12:37 AM
Last Post: JwalantBhatt0602
Question QTP not performing iterations based on local data sheet Breaker 18 56,822 01-25-2016, 04:32 PM
Last Post: arunshuklainbox

Forum Jump:


Users browsing this thread: 1 Guest(s)