Welcome guest. Before posting on our computer help forum, you must register. Click here it's easy and free.

Author Topic: my batch file requesting user input does not work  (Read 3477 times)

0 Members and 1 Guest are viewing this topic.

yates319

  • Guest
my batch file requesting user input does not work
« on: November 08, 2004, 11:59:12 AM »
Please help.  I am using the set command in a batch file and it displays the window but does not do anything but go off the screen after a selection is entered.  Please help... ??? ???

Dusty



    Egghead

  • I could if she would, but she won't so I don't.
  • Thanked: 75
  • Experience: Beginner
  • OS: Windows XP
Re: my batch file requesting user input does not w
« Reply #1 on: November 08, 2004, 03:10:21 PM »
Very hard to advise without you posting your code.  See here:

http://www.computerhope.com/sethlp.htm#04

One good deed is worth more than a year of good intentions.

yates319

  • Guest
Re: my batch file requesting user input does not w
« Reply #2 on: November 09, 2004, 08:00:46 AM »
I tried the above and I get the same results.  When I make a selection it just blanks off my screen and does not do anything.  I even tried the test print script that is posted here and I get the same results.

Thanks for any and all of your help.  My file is posted here...

'RemoteSASI.bat Provides remote access to SASI at all Seven School Locations
'This file creates a menu for remote access to SASI for School Social Workers
'     and Psychologists...


@echo off
:start
cls
echo.
echo  Which school would like to access?
echo.
echo.
echo.
echo 0.  Dinwiddie High School
echo 1.  Dinwiddie Middle School
echo 2.  Dinwiddie Elementary School
echo 3.  Southside Elementary School
echo 4.  Sunnyside Elementary School
echo 5.  Rohoic Elementary School
echo 6.  Midway Elematary School
echo 7.  Quit
echo.
echo.
set userinp =
set /p userinp= Choose a number (0-7):
if not '%userinp%'==" set userinp=%userinp:~0,1%
if '%userinp%'=='7'goto END
if '%userinp%'=='6' goto MES
if '%userinp%'=='5' goto RES
if '%userinp%'=='4' goto sun
if '%userinp%'=='3' goto SES
if '%userinp%'=='2' goto DES
if '%userinp%'=='1' goto DMS
if '%userinp%'=='0' goto DHS
echo invalid choice
goto start

:MES
C:sasixp\sasixp.exe


:RES
echo Test
call res

:SUN
call sun

:SES
call ses

:DES
call des

:Middle
call middle

:High
call high

c:sasixp.exe

:end
exit

merlin_2

  • Guest