During test run,How will you copy/paste from/to clipboard?

Answers were Sorted based on User's Feedback



During test run,How will you copy/paste from/to clipboard?..

Answer / zayed

Customise the below function for the object and c if this
is useful.

Function f_CopyAllToClipBoard ()
Dim vText, vWindow_PuTTY_WMenu_CopyAllToClipboard
Set vWindow_PuTTY_WMenu_CopyAllToClipboard = Window
("nativeclass:=PuTTY").WinMenu("menuobjtype:=4")
vWindow_PuTTY_WMenu_CopyAllToClipboard.Select "Copy All
to Clipboard"
'Clipboard object
Set cb=CreateObject("Mercury.Clipboard")
' Get the text on the system clipboard.
vText=cb.GetText
' Release the Clipboard object.
Set cb=nothing

f_CopyAllToClipBoard = vText
End Function

Is This Answer Correct ?    6 Yes 0 No

During test run,How will you copy/paste from/to clipboard?..

Answer / akshara

we will take a snap shot of that one. that is

Is This Answer Correct ?    1 Yes 3 No

During test run,How will you copy/paste from/to clipboard?..

Answer / nanda.d reddy

use the shell scripting sendkeys method:

set oShell = CreateObject("wscript.shell")

oShell.Sendkeys "^A" (Pressing the Ctrl+A keys)

oShell.sendkeys "^C" (Pressing the Ctrl+C keys)
OShell.sendkays "^V" (Pressing the Ctrl+V keys)

Is This Answer Correct ?    4 Yes 6 No

Post New Answer

More QTP Interview Questions

what is error and fault in terms of software quality?

0 Answers   TCS,


I want to install qtp software in my system, My operating system is vista . Anybody please suggest me how to get QTP software with licence key

2 Answers  


What is log file?How to write log file code?

2 Answers   Apps Lab, Value Labs,


in which case & which method we can use "native" property of an object ?

1 Answers  


How should i find out whether the cursor is moving horizantally. when tabbing continuously

2 Answers   Livetek,






Hi All, I have QTP installed on my machine but the application under test (AUT) is on remote desktop.My scenarios is like that,it should contain following steps. 1)Automatically it should click on start and then on remote desktop connection. 2)it should enter the IP address and then connect to remote desktop. 3)and then it should be able to record the application in remote machine and then run it also. Can somebody tell me how to record the application which is in remote machine.

0 Answers  


I have a drop down box to show selected number of records in result page.It contains 4 items like 10, 25,50 and 100. when i was recordes script for seelcting each item and checking selecting number of records in the result page( it is in the same page in the table format)it is generating a new page with same controls( objects) in the OR. how to avaid these in OR? is it possible to write DP for only these lines?, remaining(remaingin lines of code) objects i want use from OR only. One more problemis if change ( add /remove properties of an OBJECT in OR , my ( recorded )application is not running.

5 Answers   Virtusa,


Read excel using qtp descriptive programing

2 Answers   TCS,


is it possible to check the text displayed in the tool tip using QTP? if so, how?

6 Answers  


How to interact tool & application build in QTP?

0 Answers  


How QTP recognizes Objects in AUT?

8 Answers   Blue Star,


what is main diff of qtp8.2 and qtp9.0?

1 Answers   Covansys,


Categories