Skip to main content
I need to create a validation rule that would only fire if the user was creating a recurring event.  Basically, there are a couple of custom fields that do not apply to the "master" of the recurrence, but only to the individual instances.

 

Best I can determine, the only way to differentiate the "series master" event versus the individual instances is the field "IsRecurrence". Unfortunately, that field is not exposed to validation rules. Actually, none of the recurrence-related fields appear to be exposed.

 

Does anyone know of another workaround that could identify when the user has clicked the checkbox for "create recurring series of events?" so that I could tie a validation rule to it?

 

Thanks!
1 个回答
  1. 2013年6月2日 11:25
    atsdatajunkie,

     

    I don't think you can create a Validation Rule for recurring events because fields are not exposed in Validation Rules. But you can create an Apex trigger on Event to achieve your requirement.

     

    Before you go to create an Apex trigger just read these helpful articles by salesforce.com.

     

    http://www.salesforce.com/us/developer/docs/api/Content/sforce_api_objects_event.htm

     

    http://ap1.salesforce.com/help/doc/en/activities_creating_recurring_events.htm

     

    Recurring Events have limitations:

    • An Event object that is defined as recurring is not processed in bulk for insert, delete, or update triggers.

    • A trigger invoked by an insert, delete, or update of a recurring event or recurring task results in a runtime error when the trigger is called in bulk from the

      Force.com API.
0/9000