Forum: Ruby automated mailing

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
sapzz (Guest)
on 2006-02-02 08:24
(Received via mailing list)
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
James B. (Guest)
on 2006-02-02 08:54
(Received via mailing list)
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
http://www.artima.com/rubycs/ - 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
Robert K. (Guest)
on 2006-02-02 11:41
(Received via mailing list)
sapzz wrote:
>
> #myMail=nothing
>
>
> thanks
> Sapna

http://www.ruby-doc.org/stdlib/libdoc/net/smtp/rdo...

    robert
This topic is locked and can not be replied to.