How to pass a variable in Dos Command using QTP?
Eg:
Dim path1, path2
path1 = "C:\Test\sample1.doc"
path2 = "C:\Test\sample2.doc"
How can we pass these path1 and path2 inside the "copy" dos
command?
I tried like this. this is not working.
oShell.run "cmd /K copy" &path1 &path2
Answer / raghuram
Dim oShell
Set oShell = CreateObject ("WSCript.shell")
oShell.run "cmd /K CD C: & Dir"
Set oShell = Nothing
I was able to do in this way....you can try and let me know
| Is This Answer Correct ? | 3 Yes | 6 No |
how do check the links in a webpage ?
What is Regular Expressions?
what is descriptive.create()in qtp?
You have a WebTable in Web application. When you Record a Scenario using QTP, WebTable didn't recognized and also Repository is not having Webtable information. In this case How to find RowCount and Coloumn Count?
how to identify an object which is not in the object repository identification can be done using descriptive programming.
How u do the back end testing in QTP?
On a web application I want to select list item 5 from a dropdown list. but QTP identifying this object as winobject. Then how can we select list item 5 from that dropdown list.
How to read a text file from QC using QTP. I would like to do something like this. But instead read a file from QC and NOT from my local drive. Set fso = CreateObject("Scripting.FileSystemObject") Set InputFile = fso.OpenTextFile("C:\test.txt", ForReading) Thanks
in qtp 3 sheets is there in data table like global, action1, action2. I want to check the rows and columns in action2. how can check using script?
Is it possible to call win runner script in qtp?
What is the concept of firewalls?
Hi, Is there any function or vbscript in QTP to clear the cookies,sessions. Please help me in this.