I'm trying to reproduce the "Created By" and "Modified By" fields in one of my Visualforce pages, and I'm almost there.
<tr>
<td>Created By</td>
<td>
<apex:outputLink value="/{!Custom_Object__c.CreatedBy.Id}">
{!Custom_Object__c.CreatedBy.Name}
</apex:outputLink>
<apex:outputText value=", {!Custom_Object__c.CreatedDate}"/>
</td>
</tr>
I need to replace the text Created By with a dynamic label localized for the current user. I've tried {!$ObjectType.Custom_Object__c.Fields.CreatedBy.Label}, but I get an Unknown property error when I try to save. I can't use Fields.CreatedByID.Label since that's actually the text Created By ID.
Do I need to do something with getChildRelationships()? Look it up in my Apex code and expose it to Visualforce?
Or is this a case where I'm not going to find a label that contains a localized version of Created By and I have to choose between Created By ID, Created Date, or creating my own label and translations?
