It is sure possible. In both batch files and .VBS files you can access command line parameters. In a batch file you can refer to them by parameter position like %1, %2, etc... in a .VBS file you can use the WScript.Arguments.Unnamed method, example below Set objArgs = WScript.Arguments.Unnamed For I = 0 to objArgs.Count - 1 msg = msg+objArgs(I)+" " Next WScript.Echo msg : Hi : I currently have a batch file that I use to call : a SAS program. : I would like to convert the batch file into : VBSCRIPT file. : When I call the SAS program from the batch file : I supply the following information on one line: c:\program files\sas\sas : 9.1\sas.exe : -sysin "c:\mypgmlib\prodexec.sas" : -autoexec "c:\mypgmlib\autoexec.sas" : -sysparm "%applib% %appcode% %pgmname%" : -nosplash : -icon : Everything is hard-coded except for the following parameters. : that I pass to the batch file: %applib% = COMSCAT : %appcode% = RPT : %pgmname% = RPT12000 : Can Vbscript be used to call the SAS program in a similar fashion? : I would like to start a vbscript file using 24X7 one : the command line. Is this possible? : c:\mylib\startpgm.vbs comscat rpt rpt12000
|