Is it possible to add a delay in CRMScript? Say i want to wait 5 minutes before sending an email when the script is triggered.
All Replies (1)
Hi Frederic
I'd solve this by making a queue table and a scheduled script.
You could make a queue of emails to send in an extra table. In the trigger you add the email/message ID/ticket ID/whatever fits your needs, to the queue. Then, make a separate script responsible for sending the emails and run the script as a Scheduled Task every X amount of minutes. You might not be able to send it exactly at 5 minutes after if that matters, but you could at least make sure you never send the email before 5 minutes has passed.
Hope this helps.