Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Check points in QTP
#1
Solved: 10 Years, 8 Months, 4 Weeks ago
Hi

I have 3 text boxes in my application:

1:amount
2Tongueercentage_of_amount
3. New_amount

Now i wish to make a check point in my script, that checks that:
New_amount = Percentage_of_amount*amount

is TRUE

How do i do that ?
Reply
#2
Solved: 10 Years, 8 Months, 4 Weeks ago
Parameterize the New_Amount value with Environment option. See the script below

Code:
A = Browser("xxxxxx").Page("xxxxx").WebEdit("amount").GetROProperty("Value")
B = Browser("xxxxxx").Page("xxxxx").WebEdit("Percentage_of_amount").GetROProperty("Value")
Environment.Value("New_amount ") =  int(A) + Int(B)

Browser("xxxxxx").Page("xxxxx").WebEdit("New_amount").Set Environment.Value("New_amount")

Browser("xxxxxx").Page("xxxxx").WebEdit("New_amount").Check CheckPoint("New_amount")

But You need to do the following to Parameterize New_Amount

Go to the CheckPoint properties window for New_Amount checkpoint and select Value property - > Select Config Value Parameter -> Select the Option as Environment and enter name as it used in Script.

Thanks,
Vijay
Reply
#3
Solved: 10 Years, 8 Months, 4 Weeks ago
Thx Vijay, gives me something to work on.
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Check points on dynamically imported image? bfakruddin 2 2,371 01-03-2009, 04:01 PM
Last Post: bfakruddin

Forum Jump:


Users browsing this thread: 1 Guest(s)