vendredi 8 juillet 2016

Something problematic in my batch program - IF after GOTO

My code is the following: And whenever I try, it just pops up as an error, which is at the bottom to replace the filler.

:main
    cls
    echo Booting up MS-DOS 1.0 for Windows...
    pause
    set /p Input1="C:\> "
    if %Input1% ==win
    (goto win)
    if %input1% ==edit
    (goto edit)
    if %input1% ==qbasic
    (goto qbasic)
    if %input1% ==cd
    (goto cd DOS)

:win
    echo Really? This is DOS FOR Windows.
    goto main

:edit
    echo Not yet.
    goto main
:qbasic
    echo Troubleshooting.
    goto main

:cd DOS
    echo Just a joke.
    pause 10
    goto main

The error is a syntax error.

Aucun commentaire:

Enregistrer un commentaire