Computing.Net > Forums > Programming > Batch help!

Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.

Batch help!

Reply to Message Icon

Name: madlan
Date: January 31, 2003 at 12:00:20 Pacific
OS: 98se
CPU/Ram: p4 512mb
Comment:

A friend and i have been working on a file system.
when you run query.bat, you are asked what is the server name? and what is the pc name? (local pc)

It then saves the two as temp batch files. with set command in each.

The varibles SHOULD then be passed onto the install.bat, but somethings notworking, would you be kind enough to take a look?

its for windows 98SE

is there a way of making it more simple!
I have tryed to do the prompting in dos, but 98 doesnt have the prompt command...

At the end of the day, i just want the %server% and %pcname% to be chosen ONCE by the user, when query is run, then i want install.bat to be able to reuse the inputed data.

This is the starting batch file:

>>>>>>>>>>>>>>>>>>>query.bat>>>>>>>>>>>>>>>>>>>>>>>>>
:: start query
@echo off
start /w wscript.exe test.vbs
call ~server.bat
call ~pcname.bat
del ~pcname.bat
del ~server.bat
call install.bat %pcname%
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>


The first batch file calls this one, passing on the varibles it has gained from the user:

>>>>>>>>>>>>>>>>>>install.bat>>>>>>>>>>>>>>>>>>>>
@echo off
if "%1"=="GoTo" goto %2
%comspec% /e:4096 /c %0 GoTo start
goto eof
:start


for %%? in (%SERVER%\PACKAGES\*.exe) do call %0 GoTo process %%?
goto eof
:process
FIND "%3" nul
if not errorlevel=1 goto eof
call %3
echo %3>> %server%\LOGS\%pcname%.txt
exit
:eof
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>



Sponsored Link
Ads by Google
Reply to Message Icon

Related Posts

See More







Post Locked

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.


Go to Programming Forum Home


Sponsored links

Ads by Google


Results for: Batch help!

XCOPY - Batch Help www.computing.net/answers/programming/xcopy-batch-help/10929.html

Batch help - FTP but code cycles? www.computing.net/answers/programming/batch-help-ftp-but-code-cycles/15651.html

Batch Help www.computing.net/answers/programming/batch-help/5335.html