Thread Rating:
  • 1 Vote(s) - 2 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Arguments to pass while using Extern.ShellExecute command in QTP
#2
Solved: 11 Years, 3 Months, 1 Week ago
Parameters for Shellexecute function are (in sequence)
hwnd - Long, Optional : handle to the owner window used
lpOperation - String,Optional : a verb, that specifies the action to be performed. could be like edit, explore, open etc
lpFile - String,Required : specifies the file or object on which to execute the specified operation
lpParameters - String,Optional: specifies an executable file
lpDirectory -String,Optional : default (working) directory for the action
nShowCmd - Long, Required (Not 100% sure about required/optional) : flag that specify how an application is to be displayed when it is opened

hope this will help you.
by the way why dont you use a bit easier way to run a batch file using Wscript.shell
e.g.
Code:
Dim oShell
Set oShell = CreateObject ("Wscript.shell")'
oShell.run "C:\Share\Shri\shridos.bat"

Reply


Messages In This Thread
RE: Arguments to pass while using Extern.ShellExecute command in QTP - by Saket - 11-11-2010, 08:28 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Telnet command not recognized Sanjana1987 1 2,019 09-20-2017, 03:16 PM
Last Post: Ankur
  WinListView set item command Shahino007 0 2,632 10-06-2015, 03:57 PM
Last Post: Shahino007
  PASS/FAIL in QTP badri 3 6,165 12-05-2014, 03:26 AM
Last Post: kiranpol
  Same command needs to be performed twice to actually perform it pistaa 2 2,884 04-25-2014, 01:26 PM
Last Post: pistaa
Exclamation Getting run time error while executing the QTP script in command prompt. vishruth143 1 5,619 07-15-2013, 05:41 PM
Last Post: vinod123

Forum Jump:


Users browsing this thread: 1 Guest(s)