Sendmail.txt

  • Uploaded by: Pranav
  • 0
  • 0
  • August 2019
  • PDF

This document was uploaded by user and they confirmed that they have the permission to share it. If you are author or own the copyright of this book, please report to us by using this DMCA report form. Report DMCA


Overview

Download & View Sendmail.txt as PDF for free.

More details

  • Words: 88
  • Pages: 1
Dim Dim Dim Dim Dim Dim Dim

SMTPServer SMTPPort Mail_from Mail_to Subject Body Attach

SMTPServer = WScript.Arguments(0) SMTPPort = WScript.Arguments(1) Mail_from = WScript.Arguments(2) Mail_to = WScript.Arguments(3) Subject = WScript.Arguments(4) Body= WScript.Arguments(5) Attach= WScript.Arguments(6) set imsg = createobject("cdo.message") set iconf = createobject("cdo.configuration") Set Flds = iConf.Fields With Flds .Item("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2 .Item("http://schemas.microsoft.com/cdo/configuration/smtpserver") = SMTPServer .Update End With With iMsg Set .Configuration = iConf .To = Mail_to .From = Mail_from .Subject = Subject .TextBody = Body .AddAttachment Attach .fields.update .Send End With set imsg = nothing set iconf = nothing

More Documents from "Pranav"