S
Simon Brookman
In Performance Monitor I have set up an Alert for low disk
space and this sends me a message fine. As I am not
always going to be at my computer I would like to email a
group of people as well. I have written a Mail.js which
works fine if I run it manually. The problem is I can run
it if I list this program in the action tab and check run
this program ?? Can this run .js or does it have to be
a .exe?
var theApp, theNameSpace, theMailItem
var recipient = "email address"
var subject = "Low Disk Space"
var msg = "Disk Space is below 1MB, Please delete some
files"
sendmail ( recipient, subject, msg)
function sendmail (recipient, subject, msg)
{
var theApp = new ActiveXObject("Outlook.Application");
var theNameSpace = theApp.GetNameSpace
("MAPI").CurrentUser;
var theMailItem = theApp.CreateItem(0);
theMailItem.Recipients.Add (recipient);
theMailItem.Subject = (subject);
theMailItem.Body = (msg);
theMailItem.Send;
theNameSpace.Logoff;
}
space and this sends me a message fine. As I am not
always going to be at my computer I would like to email a
group of people as well. I have written a Mail.js which
works fine if I run it manually. The problem is I can run
it if I list this program in the action tab and check run
this program ?? Can this run .js or does it have to be
a .exe?
var theApp, theNameSpace, theMailItem
var recipient = "email address"
var subject = "Low Disk Space"
var msg = "Disk Space is below 1MB, Please delete some
files"
sendmail ( recipient, subject, msg)
function sendmail (recipient, subject, msg)
{
var theApp = new ActiveXObject("Outlook.Application");
var theNameSpace = theApp.GetNameSpace
("MAPI").CurrentUser;
var theMailItem = theApp.CreateItem(0);
theMailItem.Recipients.Add (recipient);
theMailItem.Subject = (subject);
theMailItem.Body = (msg);
theMailItem.Send;
theNameSpace.Logoff;
}