Sending e-mail from cmd line

Forum regarding Windows Software and Home Automation Domotica.
Post Reply
Edwin2008
Advanced Member
Advanced Member
Posts: 721
Joined: Fri Nov 28, 2008 4:14 pm
Location: Netherlands

Sending e-mail from cmd line

Post by Edwin2008 »

This is a nice tool to send notifications http://caspian.dotconf.net/menu/Software/SendEmail/
MindBender
Advanced Member
Advanced Member
Posts: 640
Joined: Sun Apr 30, 2006 5:31 pm
Location: Netherlands
Contact:

Sending e-mail from cmd line

Post by MindBender »

Uhm, I'm sorry, but that program is a solution to no problem at all. Sending email from the command line can easily done by opening a telnet session to you SMTP server, using the telnet command, and sending SMTP commands:<ul><li>Type telnet server.com 25
(where "server.com" is the name of the smtp (outgoing) server of your email provider, such as smtp-server.austin.rr.com). This can be found by checking your account info in the program you normally use for email.</li><li>Type HELO server.com</li><li>Type MAIL FROM: you@server.com
You may get a message saying "250 ok"</li><li>Type RCPT TO: Friend1@anotherserver.com, friend_two@someotherserver.org, friend.3three@Someserver.com
Again, You may get a message saying "250 ok"</li><li>To write the message, type DATA, followed by your message.</li><li>To end the message, put a period on a new line by itself and press Enter.</li><li>Type QUIT to exit Telnet.</li></ul>See http://www.wikihow.com/Send-Email-Using-Telnet for an easy guide on emailing from the command line. Above is just a small example, there are much more options and command available, see the SMTP protocol (http://en.wikipedia.org/wiki/Simple_Mai ... r_Protocol) for details.
Jfn
Member
Member
Posts: 332
Joined: Tue Feb 26, 2008 2:01 pm
Location: Netherlands
Contact:

Sending e-mail from cmd line

Post by Jfn »

Or use BLAT (http://www.blat.net/ when you are on Windows.
Edwin2008
Advanced Member
Advanced Member
Posts: 721
Joined: Fri Nov 28, 2008 4:14 pm
Location: Netherlands

Sending e-mail from cmd line

Post by Edwin2008 »

@mindbender. I think that blat or sendemail provide an easier approach for sending an e-mail from a batch file or commandline
@jfn. didn't find blat. looks good
Post Reply

Return to “Windows Forum”