|
|
|
|
Using QTP to capture screen shot
|
|
01-31-2012, 11:08 PM
Post: #1
|
|||
|
|||
|
Using QTP to capture screen shot
Using QTP it is possible to capture screenshots and save the file in a .bmp or png,etc file format.Here is an example I would like to share. Code: browser("name:=Google Maps").Page("title:=Google Maps").CaptureBitmap "c:\Googlemaps.bmp" |
|||
|
02-01-2012, 05:11 PM
Post: #2
|
|||
|
|||
|
RE: Using QTP to capture screen shot
I would like to add one more point to it. png format takes less memory than bmp.
We can even associate the screenshot file to HP Run Result Viewer. strFileName="c:\Googlemaps.png" browser("name:=Google Maps").Page("title:=Google Maps").CaptureBitmap strFileName Reporter.Reportevent mivPass,"Screenshot Capture","Screenhot Captured.",strFileName The last one is the optional parameter which we can specify in the reporterevent in order to see the screenshot in the result viewer itself. Regards, Ankesh |
|||
|
02-03-2012, 08:37 AM
Post: #3
|
|||
|
|||
RE: Using QTP to capture screen shot
(02-01-2012 05:11 PM)Ankesh Wrote: I would like to add one more point to it. png format takes less memory than bmp. reporter.ReportEvent throws error, it doesnt support 4 properties in qtp 9.2, dont know about other versions |
|||
|
02-03-2012, 10:48 AM
Post: #4
|
|||
|
|||
|
RE: Using QTP to capture screen shot
Rajpes,
I am not sure abt the versions which support this property. But it works fine with QTP 11.0. I will check once in QTP 10.0 and update you the same. Regards, Ankesh |
|||
|
02-03-2012, 12:11 PM
Post: #5
|
|||
|
|||
|
RE: Using QTP to capture screen shot
Works well with QTP10.0.
|
|||
|
02-07-2012, 08:20 PM
Post: #6
|
|||
|
|||
RE: Using QTP to capture screen shot
(02-03-2012 08:37 AM)rajpes Wrote:(02-01-2012 05:11 PM)Ankesh Wrote: I would like to add one more point to it. png format takes less memory than bmp. Should work fine with 9.2 with the below statement? Reporter.Reportevent micPass,"Screenshot Capture","Screenhot Captured."&strFileName&" Is the file name" Basanth QTP On Unix- Java Way - Without Putty or Terminal Emulation You have no idea how high I can fly... |
|||
|
« Next Oldest | Next Newest »
|
| Possibly Related Threads... | |||||
| Thread: | Author | Replies: | Views: | Last Post | |
| Capture screen shot for unexpected Errors. | uma87 | 5 | 1,368 |
01-07-2012 10:17 AM Last Post: ravi.gajul |
|
| How to get uppermost java object displayed on screen using QTP | shirkaan_2010 | 1 | 1,771 |
07-29-2011 01:41 PM Last Post: rajpes |
|
| How to capture text from a tooltip using QTP | sasmitakumari | 1 | 2,590 |
04-28-2011 04:18 PM Last Post: quark76 |
|
| Attach screen shot to QC with QTP test run in QC | santu.qtp | 2 | 1,864 |
03-22-2011 03:28 PM Last Post: chandu |
|
| incorporate active screen shot in result .pdf file in qtp11 | prodipto | 2 | 1,021 |
02-25-2011 09:19 AM Last Post: prodipto |
|
User(s) browsing this thread: 1 Guest(s)
|
|

Search
Member List
Calendar
Help



