Povide the bat file 'Driverbat.bat' remove ' sign and put bat under folder C:\QTP_Resource.
'cd C:\QTP_Resource
'DriverScript_QTP
'C:\QTP_Resource\Utility2.exe auto some other utility
'Exit
In QC > Create a VAPI-XP test > in test script put the code
Dim objShell
Set objShell = CreateObject("WScript.Shell")
'objShell.Run "CMD.exe"
objShell .Run "%comspec% /k c: & cd C:\QTP_Resource Driverbat.bat"
BR>
'objShell.Run "%comspec% /k c: & cd C:\QTP_Resource\\Driverbat.bat"
BR>
'qtAppWin.sendkeys "~"
No comments:
Post a Comment