p2p.wrox.com Forums

Need to download code?

View our list of code downloads.


  Return to Index  

proasp_codeclinic thread: send email automaticlly


Message #1 by "Dragan loncar" <draganl@s...> on Sat, 8 Jun 2002 23:44:42
Sorry it took me a while to respond, been busy. :)

The line objMail.Send will send your email automatically as long as you're 
running this application (as a .vbs), or if you're accessing the webpage 
with the code in it.

Sandra ^_^

> Hi Sandra
Thanks for your help but I want to send email without click on button to
activate this code. For example if presenttime time reach 10 days what you
write in code that emails are sent atomically. I am not sure probably using
application. Do you have idea how do it
Thanks


> Hi!
>
> You can do an if-else statement using the CDONTS object.
> I would gather that your present_time/send_time field is a date. Thus
> ie.
>
> set objMail = Server.Createobject("CDONTS.NewMail")
> objMail.from = "from_me@h..."
> objMail.to = "to_recipient@h..."
> objMail.subject = "Notification"
> objMail.body = "Just wanted to let you know that..."
>
> send_time = day(present_time) + 10
>
> if day(present_time) = send_time then
>    objMail.Send
> end if
>
> HTH, Sandra
>
> > Hi everyone
> I>  have database with field sendtime. I want to send emails using cdonts
> w> hen present time equals time from field sendtime.(10 days from now).
> Does
> s> omebody has idea how I can do that. What I can use that present time
> a> lways runs .
> P> lease help me.
> ---
> Change your mail options at http://p2p.wrox.com/manager.asp or
> to unsubscribe send a blank email to

>



  Return to Index