0

I am using recordsetvar with related list to access all contacts and opportunities under a account, but when I try to access events it throws error as "Events Is Not a valid child relationship name for entity account." Here's my code.

<apex:page standardController="Account" recordSetVar="accs"> <apex:repeat value="{!accs}" var="a"> <apex:pageBlock title="ACCOUNT NAME :: {!a.name}"> <apex:relatedList list="Contacts" subject="{!a.id}" /> <apex:relatedList list="Cases" subject="{!a.id}" /> <apex:relatedList list="Opportunities" subject="{!a.id}"/> <!-- <apex:relatedList list="Events" subject="{!a.id}"/> ERROR:'Events' is not a valid child relationship name for entity Account--> </apex:pageBlock> </apex:repeat> 

1
  • 2
    OpenActivities or ActivityHistories Commented Jun 29, 2017 at 13:25

1 Answer 1

2
<apex:page standardController="Account" recordSetVar="accs"> <apex:repeat value="{!accs}" var="a"> <apex:pageBlock title="ACCOUNT NAME :: {!a.name}"> <apex:relatedList list="Contacts" subject="{!a.id}" /> <apex:relatedList list="Cases" subject="{!a.id}" /> <apex:relatedList list="Opportunities" subject="{!a.id}"/> <!-- <apex:relatedList list="**OpenActivities**" subject="{!a.id}"/> ERROR:'Events' is not a valid child relationship name for entity Account--> </apex:pageBlock> </apex:repeat> 
1
  • its openactivities Commented Jun 29, 2017 at 13:43

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.