Page 1 of 1

error bad command or file name

Posted: 28 Jun 2010 11:55
by flyhigh427
hi
im using windows 98 boot disk.
i seem to be getting the error around the choice part i think
could anyone help
thanks

Code: Select all

@echo off
:menu

cls
echo    programs MENU
echo    ==========
echo.
echo    1 - pqmagic
echo    2 - pqdi
echo    3 - editbini
echo    4 - ghost3
echo    5 - ptedit
echo    6 - Quit
echo.
choice /c:123456>nul

if errorlevel 6 goto done
if errorlevel 5 goto ptedit
if errorlevel 4 goto ghost3
if errorlevel 3 goto editbini
if errorlevel 2 goto pqdi
if errorlevel 1 goto pqmagic

goto menu

:pqmagic
cd pmdos
pqmagic
goto menu


:pqdi
cd pqdi
pqdi
goto menu

:editbini
cd editbini
editbini
goto menu

:ghost3
cd ghost3
ghost
goto menu

:ptedit
cd ptedit
ptedit
goto menu


Re: error bad command or file name

Posted: 28 Jun 2010 12:48
by aGerman
It's not that easy to answer.
Indeed you would need choice.exe to use the CHOICE command. Idk if you can use it on your boot disk. Download it (direct download link!):
ftp://ftp.microsoft.com/Services/TechNet/samples/PS/Win98/Reskit/SCRPTING/CHOICE.EXE
and save it in the same folder where the batch file is placed. Hope that helps.

Regards
aGerman

Re: error bad command or file name

Posted: 28 Jun 2010 14:43
by flyhigh427
that did it thanks