Automated mailing

Hi guys,
I want to automatically generate emails on specific events.
I am using the following script in ruby. It gives runtime error that
parameter missing
how do I go about it???

require ‘win32ole’
myMail= WIN32OLE::new(“CDO.Message”)
myConfig= WIN32OLE::new(“CDO.Configuration”)

#myMail=CreateObject(“CDO.Message”)
myMail.Subject=“Sending email with CDO”
myMail.From=“my email id”
myMail.To=“receipients email”
myMail.TextBody=“This is a sample scripting message.”
myConfig.Fields.Item.SmtpMail.SmtpServer = "mail.persistent.co.in "
myConfig.Fields.Item.smtpport= 25
#myConfig.Update

#myMail.Send
#myMail=nothing

thanks
Sapna

sapzz wrote:

Hi guys,
I want to automatically generate emails on specific events.
I am using the following script in ruby. It gives runtime error that
parameter missing
how do I go about it???

How do you go about what?

Figuring out the missing parameter?

Sending mail some other way?

Is there a line number given with the “parameter missing” error?

Do you have working examples in JScript or VB Script o can use for a
comparison? (Try MSDN for sample code.)


James B.

http://www.ruby-doc.org - Ruby Help & Documentation
Ruby Code & Style - The Journal By & For Rubyists
http://www.rubystuff.com - The Ruby Store for Ruby Stuff
http://www.jamesbritt.com - Playing with Better Toys
http://www.30secondrule.com - Building Better Tools

sapzz wrote:

#myMail=nothing

thanks
Sapna

http://www.ruby-doc.org/stdlib/libdoc/net/smtp/rdoc/index.html

robert