1

Apologies if I am asking a stupid question here, but here is my scenario:

I have a custom object, say A, which has two lookups: One to a standard object (Lead) and,
Another to a custom object, say B.

The name of the two lookups on A are B__c and Lead__c.

Now, on the related list for A on Lead's page-layout, how can I show the fields belonging to B? Is it even possible? The user interface doesn't seem to allow me to do this, but I was trying to use something like:

<relatedLists>
    <fields>B__c.some_custom_field__c</fields>
    <relatedList>A__c.Lead__c</relatedList>
</relatedLists>

in the layout metadata file, but it doesn't work. I get a message that says something like:
Invalid field in related list...

Thanks in advance!

0

1 Answer 1

0

You cannot show complete related list. However, you can show only fields.

To get fields from B to A, use the below fields

A__c.B__r.Name

A__c.B__r.Id

A__c.B__r.someCustomFieldOnB__c
1
  • in addition to sfdcFanBoy's answer, if you are able to convert B's relationship field from look up to master detail on A object, you dont need formula fields. you can easily put B's fields on related list on Lead page layout. May 16, 2016 at 8:45

You must log in to answer this question.

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