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

Trigger on EventAttendee update - need to listen for Accepted / Declined status


Let's forget for a moment that the EventAttendee object has become the bane of my existence and see if there are any creative workarounds out there for the following scenario:


  1. I have an Event with one or more EventAttendees - i.e. Users that have been added as Invitees to an Event and have received an email notification when the creator of the Event clicks the 'Save and Send Update'  on a new Event
  2. I currently programmatically reference EventAttendee.Status from a controller/VisualForce page to determine whether an Invitee has Accepted or Declined said Event, but I now have a need to perform an action the moment an Event is Accepted or Declined
  3. I want to trigger an action when EventAttendee.Status changes
  4. I tried to establish an After Update trigger on EventAttendee, but received a message stating that Salesforce was not pleased with what I was trying to accomplish (sObject Type does not allow triggers: EventAttendee)


I suppose I could write a series of triggers or scheduled jobs on the related objects that need to know what's up with the EventAttendee status to go out and retrieve that information based on some event, but that is bad design and leaves gaps in the process.  EventAttendee isn't accessible by Workflow Rules, either.


Does anyone know if changes to an EventAttendee can be listened for at the Event level?  I.e. if I wrote an After Update trigger for Event, would it catch changes to EventAttendees?


Does anyone have any other creative ideas that might keep me from jumping off of a cliff?




Yeah I did this.Just write after insert and after update trigger.



If u know the list of attendees i mean like GM,VP,PM


write three for loops for each of them.



Its done


Cool.  I haven't had a chance to do R&D on you know if any of the EventAttendee information is available in Trigger.oldMap?


One of the use cases is to either prevent a specific user from changing from Accepted to Declined, or at least handle that with an email notification to a User that may not necessarily be the Event Owner.