'Batch file wont goto the right :
I have a problem with my batch file. It is referencing to Roblox Cafe games. Anyways when you enter anything into the set /p it will go to the first colon(:) and then to the second and then to the third... and so on. I tried to do something at the "if %cafeSelect%== bla bla do hgfg" but i doesn't work. I also tried to search on the internet for the problem but i didnt find anything :( Code:
set /p cafeSelect=Hello. Please choose a cafe! :
if %cafeSelect%=="Boba" do (
timeout /t 1 /nobreak
goto Boba
)
if %cafeSelect%=="Frappe" do (
timeout /t 1 /nobreak
goto Frappe
)
:invalidCafe
echo Sorry, but this cafe is invalid.
pause >nul
cls
goto start
:Boba
cls
title Boba Cafe
echo Hello! Welcome to Boba! We newly introduced the radioactive Boba, so you might just try that. But please note, that we are not responsible for any injuries this might get you.
pause >nul
goto start
:Frappe
cls
color 2A
title Frappe Cafe
echo Hello! Welcome to Frappe Cafe! My name is CASHIER. How may i help you on this Pleasant day?
pause >nul
Please help.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
