VBscript and DOS Batch scripting

killerasp

Gawd
Joined
Jul 17, 2001
Messages
963
I have a dos batch script which uses wscript to call up a *.vbs file. This vbs file does some string modifcation. The script works. I used 'msgbox" to see the output. Is there a way i could pass this querystring back out to a variable in the batch file?
 
not exactly to a variable, but you could have your vbscript instead of display a message box, write the data to stdout, and have your batch file pipe that into a text file (or back to stdout, or on to another batch file)

so
call whatever.vbs > somefile.txt
or
call whatever.vbs > newbat.bat

etc.
 
I could be way off, but can't you do everything you need to do in the .vbs.
I've done a little VB programming, a little batch "programming," and a lot of C programming and I can't think of anything I can do in batch that I couldn't do in C, albeit with a lot more work. So I assume you could get whatever done in vbs since you are already using it.
 
Sgarissta said:
not exactly to a variable, but you could have your vbscript instead of display a message box, write the data to stdout, and have your batch file pipe that into a text file (or back to stdout, or on to another batch file)

so
call whatever.vbs > somefile.txt
or
call whatever.vbs > newbat.bat

etc.


GENIUS. im going to do just that. Im going to have vbs output all the strings to the file and call a batch script to run it. NICE!
 
Back
Top