:D You script is exactly what i need but when i run the script i get the following error. I know this was posted in 2010 but hopefully you will see this. #Vbscript email parser windows 7#It may be or may not (I don't know) but in Windows 7 Enterprise 圆4 it's still valid :)ĭive in and use it now, It'll take no time. I heard from a previous post somebody thought CDO Mail was depricated. ("") = 2 ("") = "" ("") = 25 objMsg.Send Wscript.Echo "DONE" Wscript.Quit This works presently still in Windows 7. Port is TYPICALLY 25 but some providers use a custom port ObjMsg.AddAttachment "C:\ZZZ.Zip" 'NOTE: DO NOT USE AN "=" SIGN AFTER "AddAttachment" ' Also note replace and Port 25 with whatever your SMTP Server is ' using. Probably my backup logs." ' Note C:\ZZZ.Zip' is a fictional filename fill it in with your filename If you play with vbScript you ' could probably compose a very elaboborate and beautiful message ' But I'm lazy :) objMsg.TextBody = "This is a very important email and attachment. PLEASE!" ' Enter email address of sender within quotes ie objMsg.From = ' Enter destination email address in quotes. ' Create link to CDOmail Set objMsg = CreateObject("CDO.Message") ' Enter subject of message in quotes objMsg.Subject = "Subject of Message. So adding up the pieces together you'll get this. Reason being is one sends the attachment, the other allows you to specify what you're going to need, an SMTP server. Sir Horace has the right idea but you need to combine the two. 'These two scripts work for me (tested five minutes ago, 9 Apr 10, 3:58 PM) Set objMsg = CreateObject("CDO.Message") objMsg.Subject = "CDO TEST MESSAGE"
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |