You need to sign in to do that
Don't have an account?

Case View Page - RelatedList problems
I have a Visualforce page to override our Case View page, however, having problems with the following relatedLists:
<apex:relatedlist list="CaseComments" />
<apex:relatedList list="EmailMessages" />
<apex:relatedlist list="NotesandAttachments" />
<apex:relatedList list="CaseHistories" />
All are resulting in the "is not a valid child relationship name for entity Case". Any thoughts?
You missed to add subject
<apex:relatedlist list="CaseComments" subject="{!Case}" />
<apex:relatedList list="EmailMessages" subject="{!Case}"/>
<apex:relatedlist list="NotesandAttachments" subject="{!Case}"/>
<apex:relatedList list="CaseHistories" subject="{!Case}"/>
Thanks Shashikant - however, it's still giving me an error.
Adding <apex:relatedlist list="CaseComments" subject="{!Case}" /> still results in :
'CaseComments' is not a valid child relationship name for entity Case
Hi,
Please verify two things
1) Standard controller for VFP is Case
2)You are using correct relationship name
Yep, standardController is Case:
I believe it is the correct relationship name based on what I see in the schema (viewing via Eclipse), for example:
Email Message - Relationship Name: EmailMessages
CaseComment - Relationship Name: CaseComments
I was able to save this
May be some issue in your extension class, could you please share it also.
I've been able to save my page as well, and saved yours too.
However, when I view the page, I get the errors (e.g. 'CaseComments' is not a valid child relationship name for entity Case ).
Do you not get an error when you try to view the page?
Hey Andrew, did you manage to find the solution for this?
Thanks
The solution having to create the related lists with the markup manually, rather than use the standard reference. It ended up working, but was a bit time consuming.
Thanks, not what I wanted to hear though :(
<apex:page standardController="case">
<apex:dataTable value="{!Case.EmailMessages}" var="email">
<apex:column value="{!email.Subject}" />
....
</apex:dataTable>
<apex:dataTable value="{!Case.CaseComments}" var="cc">
<apex:column value="{!cc.Id}" />
.....
</apex:dataTable>
</apex:page>