(REPOST) WinXP BATCH syntex help plz! =)

G

Guest

I reposted this just now because I realized that I had
amended something on my post and it looked like it was
answered by having the "+" plus icon at the left of the
subject... so here is the revised original... =/

Thanks to who ever reads this and even those who can't
help with problem... =)

I am trying to make a BATCH file that has 4 items to
choose (1 through 4 as choices). I am having a hard time
getting the syntex correct with the IF and Set commands.
I am not sure if there is anything thing else needed. I
can create a simple 2 item menu okay. but when I get 3 or
more choices in the batch syntex I can't get it to work.

Can someone show me how to get the syntex written
correctly for this? All I need is the stuff after this
following line (that is if the following line is correct).

set /p answer=Enter Choice:

Thanks ever so much for this.. if you are wondering what
I am doing.. I am trying to put a menu for easy testing
of ping and tracert commands, but mostly ping wiht an
exit line.

One last Question.. is there a way, once the batch file
is created to set it up further where when a selection is
made you don't have to hit enter after you make the
selection... (e.g. instead of "1 then ENTER" you can just
hit "1" and the command precesses)???

Sincerely,

Kevin in Alaska
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top