Skip To Content
Get In Touch

Search...

Adding all activities on an account to an embedded visualforce page

Follow the steps below to show events/ tasks on an embedded account calendar where the event/ task doesn’t have the “related to” filled in but the “Name” is a contact on the account. This is possible using dynamic filters. Standard Salesforce shows those events/ tasks on the account even if the related to isn’t filled out because they are a contact on the account.

Step 1: Edit your event or task calendar

Step 2: Select the filter item in the calendar edit picklist.

Step 3: Add dynamic filters

  • Add “Related To” equals and then click “Dyn”
  • Add “Account” equals and then click “Dyn”
    **Note in this example Account was renamed to Organisation. if your accounts were renamed search for the the new label.

Step 5: Add the code below to a new visualforce page. Note: The highlighted part will need to be changed to reflect the name of your calendars.


<Apex:page>
<SLCA2:calendar namespace="SLCA2"
calendar="Events,Tasks"
enabled="{'Events':true,'Tasks':true}"
createable="Events,Tasks"
userAdditionalSettings="{}"
view="month"
date=""

urlparams="pv1={!URLENCODE(Account.ID)}&pv3={!URLENCODE(Account.ID)}"

readonly="{
edit            : true,
create          : true,
detail          : true,
move            : true,
hover           : true,
contextEvent    : true,
contextCalendar : true,
contextArea     : true,
cloneSharing    : true
}"

></SLCA2:calendar>
</apex:page>

Ready to see results?

Request a demo