Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Checkpoint: Image [QTP 10.0]
#1
Solved: 11 Years, 4 Months, 4 Weeks ago
Dear all,

I am able to check when an image is displayed and the check fails if it's not displayed.

But I don't know how to put a checkpoint for the absence of an image - if image is not displayed the check should pass. Is it possible? Thanks in advance for any kind of suggestion.

Kind regards,
Helen
Reply
#2
Solved: 11 Years, 4 Months, 4 Weeks ago
You can use visible property.
Reply
#3
Solved: 11 Years, 4 Months, 4 Weeks ago
Code:
result=Browser("Automation Site | Home").Page("Automation Site | Send").Image("banner").Check(CheckPoint("banner"))  
If not result Then
    'image was not matched
End If

To get the above code, I just added a checkpoint the usual way then added parenthesis after ".Check:" and after ("banner"), then assigned the result from the checkpoint to a local variable named "result".

By default, the checkpoint timeout is 0 seconds, meaning don't wait before the image appears. Just check to see if the image is there right now. Actually, it doesn't just check to see if the image exists; it also checks to see if the image is identical to the one originally captured.

In the properties for the checkpoint in your object repository, you can set the timeout - the amount of time to wait before giving up on finding the image.
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
Shy script for clicking an image in QTP Bala Preetha33 11 22,538 03-13-2013, 11:51 PM
Last Post: nikhilcogni
  Not able to insert XML Checkpoint using qtp 11 soumen 0 1,866 06-01-2012, 02:51 PM
Last Post: soumen
  Insert image in wordpad file using QTP TurtleRock 0 3,332 11-15-2011, 04:44 PM
Last Post: TurtleRock
Wink standard checkpoint and text checkpoint kiran10_rm 1 5,413 11-18-2010, 05:16 AM
Last Post: nandu
Toungue Checkpoint Image. Mukesh.Laxmidhar 2 2,822 09-21-2010, 01:01 PM
Last Post: Mukesh.Laxmidhar

Forum Jump:


Users browsing this thread: 1 Guest(s)