net send batch file new line

  • Thread starter SrA Michael Roszkowski USAF
  • Start date
S

SrA Michael Roszkowski USAF

I know you can type "CTRL+T" to get a new line in the net
send command when you're typing it from the command line.

Does anyone know how to do the same thing from a batch
file?

Here's my batch:
:: start (notify.bat)

setlocal
set msg=Node %1 down! Check OpenView immediately!
FOR /F %%i IN (notifylist.txt) DO @net send %%i %msg% > Nul
endlocal

:: end


Notifylist.txt is a text file with the single line of the
computer name that I want notified. Obviously this list
will grow to reflect all the computers that will be
notified.

The IP address is passed from the command line.

Thanks,
SrA Michael Roszkowski USAF
<[email protected]>
(Change the U to an i)
 
S

SrA Michael Roszkowski USAF

That did it... I didn't have a % in-front of the ¶
charecter.

Thank you!
 

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

Top