Dynamic label name
CashySep 9 2010 — edited Dec 19 2016Hi,
I am trying to find out whether it is possible to dynamically change the label of a TEXT_ITEM in apex.
I have a field called item_name. This is connected to an item_type which I am calculating. For example, if the item_type = 'LOCATION' I want the label of the item_name to be displayed as 'Location Name' and if the item_type = 'PERSON' I want the label to be shown as 'Person Name' and so on.
Not sure if this is possible. There is a way I can do it with hidden fields which are only visible depending on the item_type field value which have their own label, but this is a very time consuming and messy of way of doing it and would be awkward to maintain.
Any help would be great,
Chris