Print this page

Can I Create A Roll-Up Summary Field to Count the Number of Activities for an Account?

Knowledge Article Number 000187158

Roll-up Summary Fields may not be created to count Activities; however custom Apex code can achieve this functionality.


While this may not be accomplished with standard functionality, you could create an Apex Class and two Apex Triggers (one for Events and one for Tasks) in order to count the number of Activities on a given Record. This would populate into a custom Field for that Object.

The resulting Custom Field could then be used in combination with other logic if the desire is to use this in a Workflow Rule, etc.



About Roll-Up Summary Fields


promote demote