I have a custom lookup field on Activities to Business_Trip__c, allowing linking multiple meetings to one trip and to the visited Accounts. I want to create an VF approval template for the proposed trip which would include the related Events.

The code below works with


But this is the standard event WhatId relationship - not appropriate for the Business_Trip__c object. The Activity custom field lookup to Business_Trip__c tells me the Child Relationship is Meetings but the below code gets error:

Error: Invalid field Meetings for SObject Business_Trip__c  

Please advise, thanks!

<p><b>Planned Meetings:</b></p>
<table border="1" >

    <apex:repeat var="cx" value="{!relatedTo.Meetings}">
             <td>Name: {!cx.WhoId}</td>
             <td>Date: {!cx.ActivityDate}</td>
             <td>Company: {!cx.Whatid}</td>
             <td>Subject: {!cx.Subject}</td>


<p />

1 Answer 1


The relationship needs to be expressed as:

<apex:repeat var="cx" value="{!relatedTo.Meetings__r}">

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .