+ Start a Discussion

Can I use field Description Attribute as Custom Field Label



I am trying to display input fields using field sets in VF.  My field labels were too long to put in Field Label attribute so I put my label text in the field description attribute.  Is there a way to access the field description attribute and use as my label in field set input fields?


Thanks in advance.


I couldn't get at this attribute from a field.  I'd imagine that an entry from the fieldset makes the Schema.DescribeFieldResult properties available, and description isn't one of these.  InlineHelpText is though, so if you can sacrifice that you could use it as per the following example:



<apex:repeat value="{!$ObjectType.Account.FieldSets.AccountsAndContactsEdit}" var="field">