Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


what is mercury.clipboard in qtp.where we can get this in
qtp tool i.e tabs



what is mercury.clipboard in qtp.where we can get this in qtp tool i.e tabs..

Answer / nanda

HI,

"mercury.clipboard" is method to create a clipboard
object. and use to copy and paste the text.

The below Example will copy the text from PDF file to
notepad file:

note : the given files paths are in my local system. Please
give paths in ur local system.

Set clipboard = createobject("mercury.clipboard")

'Give notepad file path according to ur local system path.

filepath = "C:\Documents and Settings\Madhu
Sudhan\Desktop\example.txt"
for_reading = 1
for_appending = 8

'Please Open any pdf file in ur system. at the time of
running it should be opened and in maximize.

Window("Adobe Reader").WinMenu("Menu").Select "Edit;<Item 8>"
Window("Adobe Reader").WinMenu("Menu").Select "Edit;<Item 4>"

Set fso = createobject("scripting.filesystemobject")

Set notepad = fso.createtextfile(filepath,for_appending)

nanda = clipboard.gettext
notepad.write nanda

notepad.close

Set notepad = fso.opentextfile(filepath,for_reading)
reading=notepad.readall

msgbox reading


With Regards..
Nanda

Is This Answer Correct ?    5 Yes 0 No

Post New Answer

More QTP Interview Questions

what is Business Process Testing plz explain?

7 Answers   iFlex,


Function to convert lowercase to uppercase in QTP Pls anybody can give the answer.. Thanks in advance...

2 Answers   Navis,


how to create external data table?

1 Answers   TCS,


How many types of actions are there in quicktest professional?

0 Answers  


wht is the difference betn check point and output value?

5 Answers   BirlaSoft,


hi, In A Table there are some columns and dynamic rows and in each row in first column there is a link with name. upon clicking on that link it will show some details. write the vbscript to check that link without descriptive programming?

2 Answers   HealthAsyst,


What are metrics and matrix?

0 Answers  


PLEASE TELL ME WHEN DO YOU USE THE OBJECT SPY AT RUN TIME

4 Answers   Ordain Solutions,


hou can we use vb script in qtp could u tell me breafly

0 Answers  


Difference between copy to action and call to action?

0 Answers  


In the application that I'm testing is having a WYSIWIYG editor.QTP is recording editor's body as web element. I want to add some data to this web Element at run time. The problem is that I cant find a method to add contents to this web Element. Can any one come up with an answer for this. Thankx.

0 Answers  


How you can decide which type of object repository you have to use?

0 Answers  


Categories