function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
NinieNinie 

Task Object Email Notification

Hi..

Need some help here...Im using API to insert Task. But every time I create task using API the email notification will not be send to the Owner of the TASK. Even I set send email notification as default in UI, when I try to load using API its still not work...

 

Appreciate if anyone can give me an advise or guideline regarding this issue.

 

Thank you in advance!

Message Edited by Ninie on 07-09-2009 02:34 AM
Best Answer chosen by Admin (Salesforce Developers) 
meyerdmeyerd

Task t = new Task(Subject='Follow-up');
Database.DMLOptions dmlo = new Database.DMLOptions();
dmlo.EmailHeader.triggerUserEmail = true;
database.insert(t, dmlo);

 

Message Edited by meyerd on 12-17-2009 07:04 PM

All Answers

Edwin VijayEdwin Vijay

I believe there is a field in Tack object "Send Notification" or something like that. This field has to be set to TRUE when you insert a task from API..

 

Hope this helps..

Chirag MehtaChirag Mehta

No, there is no such "Send Notification" field @ Task. Also there is no such property @ Task, which can be set as true when inserting a task using API.

 

Following is screenshot of all properties supported by Task ..   Is there any other option to send notification on task creation using API or Apex ?

 

SabaSaba
Even i am searching desperately for Send Notification Email field in task... Any workarounds anywhere????
meyerdmeyerd

Task t = new Task(Subject='Follow-up');
Database.DMLOptions dmlo = new Database.DMLOptions();
dmlo.EmailHeader.triggerUserEmail = true;
database.insert(t, dmlo);

 

Message Edited by meyerd on 12-17-2009 07:04 PM
This was selected as the best answer
PFangPFang

Meyerd, you are the absolute greatest! I've sifted through hundreds of triggers just to get apex triggers with task notifications working and yours by far is the only one that got mine to fire. Kudos to you!

MichalMichal

How to do this with REST API?