Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Page refresh issue 1

Status
Not open for further replies.

Hondy

Technical User
Mar 3, 2003
864
GB
Hi

I have a page that pulls data from a database, when a condition is met an email is sent off. This works fine.

The page auto-refreshes every 10 minutes but if the same condition is met again it sends out another email.

Is there any solution to let it only email once then that is flagged as complete so the only emails I recieve is for new conditions? I don't want to write to the database, i'm not sure this is possible actually but I'm open to ideas...

Thanks
 
I would use the session object after I send off the email. When the page refreshes, check the condition and the session.
 
is that difficult? I'm not a programmer so is this out of my league? Any resources?
 
Not at all. Something like this:

Code:
'Put this line inside your send email sub, after the email is sent out successfully

session("sendEmail") = "Done"

'Then you check the condition & session the next time you want to send out the email 

If someCondition = "yes" and session"sendEmail" <> "Done" then
   ...
 
sorry ...typo .. shouldbe

If someCondition = "yes" and session("sendEmail") <> "Done" then
 
great, i will check that out tomorrow :)

Thanks
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top