If you’re using Windows 2000 or above, you’re in luck. User input is extremely simple. Using the ’set’ command with the /p switch provides a prompt that will allow the user to type in a string, which will then be saved to a variable of your choice. Example:

set /p NAME=Please enter your name:
echo Hello, %NAME%! How are you today?

Easy enough, right? I sure thought so.

Tags: , , ,

Bookmark: These icons link to social bookmarking sites where readers can share and discover new web pages.
  • del.icio.us
  • digg
  • Reddit
  • Technorati
  • StumbleUpon
  • Fark
  • Furl
  • Netscape
  • YahooMyWeb
  • blinkbits
  • blogmarks
  • Spurl

Comments are closed.

Recent Posts

Most Popular Posts

Categories