You need to sign in to do that
Don't have an account?

Automatic Tasks
Hi All,
I need some help creating tasks automatically.
My scenario: on each of my contacts, i have many dates (about 5 dates, in different date fields). for each of these, if filled in, I must schedule a task. this task will be scheduled to 30 days before the date occurs.
How do I do this? any 'free' code I could use?
Here's a bigger problem. if one of these dates changes, I would need to go and find the task, and modify the date. I am considering one of several ways doing this:
Any thoughts on this matter would be much appreciated.
Ben
I need some help creating tasks automatically.
My scenario: on each of my contacts, i have many dates (about 5 dates, in different date fields). for each of these, if filled in, I must schedule a task. this task will be scheduled to 30 days before the date occurs.
How do I do this? any 'free' code I could use?
Here's a bigger problem. if one of these dates changes, I would need to go and find the task, and modify the date. I am considering one of several ways doing this:
- Keep a field for each date, this is the record ID of the task created, so that I can then change it's date if needed.
- Write an code that would find the task using SOQL, and change it's date. in this case it is hard to tell if the task the right one (since I have 5 such dates)
- Keep a field on the task record, with some string identifying it as relating to the date field in question.\
Any thoughts on this matter would be much appreciated.
Ben
This scenario seems like a textbook example of timed workflows, which will even reevaluate the workflow task whenever a condition changes. Have you looked into that option?
Hope this helps.
Thanks for the post.