FileWatcher .vbs Script to send email

Discuss our other products here. Get help with installation and running, notify us of bugs, request new features and enhancements.

Moderators: DataMystic Support, Moderators, DataMystic Support, Moderators, DataMystic Support, Moderators

Post Reply
User avatar
DataMystic Support
Site Admin
Posts: 2229
Joined: Mon Jun 30, 2003 12:32 pm
Location: Melbourne, Australia

FileWatcher .vbs Script to send email

Post by DataMystic Support »

Here is a sample vbscript to sent an email - save it as 'send-email.vbs' and set FileWatcher's command field to point to this file.

See also:

Code: Select all

Option Explicit

dim objArgs 

'Set a reference to the arguments
Set objArgs = Wscript.Arguments

dim objEmail
Set objEmail = CreateObject("CDO.Message")
objEmail.From = ""
objEmail.To = ""
objEmail.Subject = "FileWatcher file attached"
objEmail.Textbody = "Please process it ASAP"

for i = 1 to objArgs.count
  objEmail.AddAttachment( objArgs(i) )


set objEmail = Nothing
Set objArgs = Nothing
(478 Bytes) Downloaded 868 times

Simon Carter, - Insulin dose calculator for Type 1 diabetes - 250,000 free software downloads
Post Reply