zingle Posted May 9, 2014 Posted May 9, 2014 Hello, I have this small batch file to make computer shutdown or reboot after "xx" seconds, to change the value "xx " the user should edit the file each time, i do not know how to make the program ask the user to chose the value of "xx" for example a dialog : "Please enter the value "xx". @echo off Title Scheduled ShutdownPC,RestartPc or Abort the two previous actions. cls echo. echo Please select an action : echo *********************** echo. echo 1) Shutdown computer in 01 minutes echo 2) Restart computer in 01 minutes echo 3) Abort all actions echo 4) exit echo. set /p web=Type option : if "%web%"=="1" shutdown -s -t 60 if "%web%"=="2" shutdown -r -t 60 if "%web%"=="3" shutdown -a if "%web%"=="4" exit goto homeThanks.
zingle Posted May 9, 2014 Author Posted May 9, 2014 http://lmgtfy.com/?q=bat+prompt+user+input Thanks for the info 1
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now