Computing.Net > Forums > Disk Operating System > Option to SKIP Set INPUT= prompt?

Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.

Option to SKIP Set INPUT= prompt?

Reply to Message Icon

Name: kev100
Date: March 27, 2006 at 19:39:09 Pacific
OS: XP PRO
CPU/Ram: PENT/512
Product: DELL
Comment:

Folks....

I'm using the Good 'ol...

set INPUT=
set /p INPUT= Enter First Name:

to get some user data.

However...I would like to give the option to SKIP entering any data without having to enter a blank (because the blank input would then overright the previous info).

Something like...
set INPUT=
set /p INPUT= Enter First Name or "S" to skip:

I'm hoping this is pretty basic....any help appreciated.

THANKS


> PLEASE CONTRIBUTE to Computing.net - Report back what did/didn't work for Others' Reference.<



Sponsored Link
Ads by Google

Response Number 1
Name: Mechanix2Go
Date: March 27, 2006 at 20:22:38 Pacific
Reply:

choice /n do you have input for me?

goto :%errorlevel%

:1
set INPUT=
set /p INPUT= Enter First Name:
goto :eof

:2


=====================================
If at first you don't succeed, you're about average.

M2Go



0

Response Number 2
Name: kev100
Date: March 28, 2006 at 09:25:32 Pacific
Reply:

In XP PRO...cmd window....I got the error:

'choice' is not recognized as an internal or external command,operable program or batch file.

Does this mean that the choice command is not part of XP's "simulated" DOS?

Thanks

> PLEASE CONTRIBUTE to Computing.net - Report back what did/didn't work for Others' Reference.<


0

Response Number 3
Name: franki
Date: March 28, 2006 at 09:58:26 Pacific
Reply:

CHOICE is for MS-DOS/W9x

http://www.computerhope.com/choicehl.htm

The posting warnings clearly state that this is not the forum for XP, it is up the page.

XP is based on NT4 and NOT MS-DOS.

CMD.EXE = NT COMMAND PROMPT
COMMAND.COM = Emulated MS-DOS Command Prompt (loosely based on MS-DOS 5/6)

http://www.microsoft.com/resources/documentation/windows/xp/all/proddocs/en-us/ntcmds.mspx?mfr=true

http://www.ss64.com/nt/

http://www.ss64.com/ntsyntax/index.html


0

Response Number 4
Name: Mechanix2Go
Date: March 28, 2006 at 22:21:57 Pacific
Reply:

Hi kev,

CHOICE is an externaql command. It's included in some versions of XP but not all. Dunno why.

I use CHOICE.COM from DOS and it seems to work OK. You can get it here:

CHOICE



If at first you don't succeed, you're about average.

M2


0

Sponsored Link
Ads by Google
Reply to Message Icon

Related Posts

See More


Formatting a 250gb IDE hd... USB 2.0 and DOS?



Post Locked

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.


Go to Disk Operating System Forum Home


Sponsored links

Ads by Google


Results for: Option to SKIP Set INPUT= prompt?

The ULTIMATE method to get user input !! www.computing.net/answers/dos/the-ultimate-method-to-get-user-input-/8711.html

HOW TO SKIP QUESTION WHILE DELETING FILE www.computing.net/answers/dos/how-to-skip-question-while-deleting-file/8619.html

how to skip question while deleting file www.computing.net/answers/dos/how-to-skip-question-while-deleting-file/8620.html