I do this all the time (run vbscript files from the command line) and yes 
it's as simple as 'cscript path-and-name-of-my-vbs-file'. You almost 
certainly would not need to qualify the path to cscript since it's in one 
of the Windows directories that's in the PATH by default.

You would, as David pointed out, need to path-qualify your vbscript 
filename.

You might want to consider using the /nologo argument to cscript to 
suppress the CScript version-identification header line in STDOUT. This 
has no functional impact but it'll make it a little easier to parse the 
returned STDOUT to see your program's output.

----------------------------------------------------------------------------------------
Joe Veilleux
IBM/Lotus Domino Server Quality Engineering
5 Technology Park Drive
Westford MA 01886
Email: joeveill...@us.ibm.com




David Bender/Austin/i...@ibmus 
04/15/2009 09:56 AM

To
"Premsudha Venkatesh" <premsudh...@sonata-software.com>
cc
staf-users@lists.sourceforge.net
Subject
Re: [staf-users] Help







According to this:  
http://windowsitpro.com/article/articleid/15226/how-do-i-run-a-windows-script-from-the-command-line.html
 


You would run it with something  like: 

STAF <local or remote machine> PROCESS START SHELL COMMAND "cscript 
myvbscript.vbs" RETURNSTDOUT STDERRTOSTDOUT WAIT 

Of course you might need to fully-qualify the path to "cscript.exe" or 
"myvbscript.vbs". 

David Bender
STAF/STAX Development
(512-286-5315)
IBM Austin Bldg. 903-5B002
Internet: bda...@us.ibm.com



"Premsudha Venkatesh" <premsudh...@sonata-software.com> 
04/15/2009 12:57 AM 


To
<staf-users@lists.sourceforge.net> 
cc

Subject
[staf-users]  Help








  
Hi, 
  
I have created a .vbs file which launches QTp and runs a test and loses 
it. 
  
Please let me know how to run this VBscript file from STAF 
  
Regards,
Prem Sudha
PH : 26610330 Extn.5234 



From: David Bender [mailto:bda...@us.ibm.com] 
Sent: Wednesday, March 25, 2009 7:27 PM
To: Premsudha Venkatesh
Cc: staf-users@lists.sourceforge.net
Subject: Re: [staf-users] Help 
  

You just submit a STAF PROCESS START request to the local or remote 
system, and specify the command to start the QTP executable and pass it 
the appropriate parameters.  For example:

STAF <local or remote machine> PROCESS START SHELL COMMAND <QTP 
executable> PARMS <arguments for the QTP executable> RETURNSTDOUT 
STDERRTOSTDOUT WAIT 

David Bender
STAF/STAX Development
(512-286-5315)
IBM Austin Bldg. 903-5B002
Internet: bda...@us.ibm.com


"Premsudha Venkatesh" <premsudh...@sonata-software.com> 
03/25/2009 07:03 AM 


To
<staf-users@lists.sourceforge.net> 
cc
  
Subject
[staf-users] Help

  


  
 





Hi 
 
How to I use STAF's PROCESS service to run a recorded script (created 
using a QTP) on a local and Remote machine 
 
Regards,
Prem Sudha
PH : 26610330 Extn.5234 
------------------------------------------------------------------------------
Apps built with the Adobe(R) Flex(R) framework and Flex Builder(TM) are
powering Web 2.0 with engaging, cross-platform capabilities. Quickly and
easily build your RIAs with Flex Builder, the Eclipse(TM)based development
software that enables intelligent coding and step-through debugging.
Download the free 60 day trial. 
http://p.sf.net/sfu/www-adobe-com_______________________________________________

staf-users mailing list
staf-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/staf-users
------------------------------------------------------------------------------
This SF.net email is sponsored by:
High Quality Requirements in a Collaborative Environment.
Download a free trial of Rational Requirements Composer Now!
http://p.sf.net/sfu/www-ibm-com_______________________________________________

staf-users mailing list
staf-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/staf-users
------------------------------------------------------------------------------
This SF.net email is sponsored by:
High Quality Requirements in a Collaborative Environment.
Download a free trial of Rational Requirements Composer Now!
http://p.sf.net/sfu/www-ibm-com
_______________________________________________
staf-users mailing list
staf-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/staf-users

------------------------------------------------------------------------------
This SF.net email is sponsored by:
High Quality Requirements in a Collaborative Environment.
Download a free trial of Rational Requirements Composer Now!
http://p.sf.net/sfu/www-ibm-com
_______________________________________________
staf-users mailing list
staf-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/staf-users

Reply via email to