0

I am trying to create an email where it will show the recipient a list of the "Review Accounts" associated with the "Review" object. Where "Review Accounts" is a Child object for "Reviews". Below is what I have but it keeps giving me the "Error: Invalid field LLC_BI__Review_Account__r for Object LLC_BI__Review__c"

<messageing:emailTemplate subject="testing email" recipientType="User" 
                          relatedToType="LLC__BI_Review__c">
  <messaging:htmlEmailBody>
    <apex:repeat var="ra" value="{!relatedTo.LLC_BI__Review_Account__r}">

    </apex:repeat>
  </messaging:htmlEmailBody>
</messaging:emailTemplate>

1 Answer 1

0

Because you are using a managed package here, it looks like your definition of the relationship name has the incorrect name space LLC_BI

You have:

value="{!relatedTo.LLC_BI__Review_Account__r}"

But the namespace looks like it is LLC based on the relatedToType

So you want:

value="{!relatedTo.LLC__BI_Review_Account__r}"

assuming that is the true relationship name; more likely, it is plural

value="{!relatedTo.LLC__BI_Review_Accounts__r}"

Check your configuration to get the correct relationship name

2
  • You were correct, it needed to be plural. I must have mistyped the namespace.
    – Heeb
    Commented Feb 4, 2021 at 16:34
  • Thank you for the help!
    – Heeb
    Commented Feb 4, 2021 at 16:35

You must log in to answer this question.

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