title: VBS script trying to email errors
body: <p>Im having problem VBS trying to email errors. here is the error
  Line 1
  Char 13
  Error Subscript out of Range
  Code 800A0009</p>
  
  <pre><code> Dim param1: param1 = WScript.Arguments(0)
  EmailTo = "name@email.com"
  Set oWshNetwork = WScript.CreateObject("WScript.Network")
  ComputerName = oWshNetwork.ComputerName
  Set objEmail = CreateObject("CDO.Message")
  objEmail.From = ComputerName &amp; "@email.com"
  objEmail.To = EmailTo
  objEmail.Subject = "TESTING"
  objEmail.Textbody = objEmail.Textbody &amp; vbCrLf &amp; "Please see attached log file for batches 
  
  unzipped yesterday."
  objEmail.Configuration.Fields.Item
  
  ("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2
  objEmail.Configuration.Fields.Item
  
  ("http://schemas.microsoft.com/cdo/configuration/smtpserver") = "mail.mail.com"
  objEmail.Configuration.Fields.Item
  
  ("http://schemas.microsoft.com/cdo/configuration/smtpserverport") = 25
  objEmail.Configuration.Fields.Update
  objEmail.AddAttachment param1
  objEmail.Send
  </code></pre>
  
  <p>Thanks for all your help!</p>