Help: I can't get nslookup.exe to work in non-interactive mode

  • Thread starter Thread starter Larry Dighera
  • Start date Start date
L

Larry Dighera

Can you get this batch file to work? Put the text below in a file
named NSLOOKUP.BAT, and run it from a command prompt.

set /p userin=Enter IP address:
nslookup %userin%
pause

For some reason it loops back to the beginning and fails to display
the output from nslookup.exe. This should be easy. I must be
overlooking something simple.

OS: MS WindowsXP Home Edition.

(Please don't tell me this is not necessary because nslookup.exe
supports interactive use. It's become more important to make it work
than to actually use it.)

ADVthanksANCE
 
set /p userin=Enter IP address:
start /wait cmd /k "nslookup %userin%"
exit
 

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

Back
Top