How to send email with an attachment using a Windows batch file

15 pts.
Tags:
Batch files
Windows Batch Files
I would like a batch file to send a email with attachments from a batch file. I would like this to automated and for it to send any file within a folder. Any help?

Answer Wiki

Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

Discuss This Question: 5  Replies

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.
  • ToddN2000
    Sounds like a homework question, What have you written for code so far?
    111,200 pointsBadges:
    report
  • Mineblock
    Nothing, I just want to see if there was a way. I've heard how to send email via batch and I'm gonna test that when I get chance. Is there way or do I just have to find another way to send attachments from a folder automatically.
    15 pointsBadges:
    report
  • ToddN2000
    Yes it can be done. That is how we get so much spam and junk e-mails. There are some legitimate uses like sending notifications to clients/customers. In this case it from an application that accesses the list of e-mails from a database and is written in either VB or C#. There are other languages as well.
    111,200 pointsBadges:
    report
  • sachprabhu
    I tried im able to send mail through batch file, but could any one advise how to send with an attachments.
    10 pointsBadges:
    report
  • carlosdl
    I've used bmail to send e-mails from batch files in the past.  I've never sent attachments, but here's an article that shows an example of that using mpack:

    Command Line SMTP Mailer for Batch Jobs
    84,535 pointsBadges:
    report

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

Thanks! We'll email you when relevant content is added and updated.

Following

Share this item with your network: