function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
AFawcett (CODA)AFawcett (CODA) 

Translation of literal text messages within Apex code?

I have been doing some research into language translation support. So far I carn't seem to find any reference as to how text used within Apex code can be translated? I guess what i am looking for is something like a Java resource bundle? Anybody got any ideas/thoughts on this?
mtbclimbermtbclimber
There is no standard support for custom labels/translated messages today in Apex.

If you'd like to see this become part of the standard offering, please vote for this idea on ideaexchange.

If you have other ideas please post them as well. We really do use this to affect prioritization of features.


claudiolmcclaudiolmc
I also had the need to translate messages inside Apex Classes, so I created a small class, a custom object and a tab to help me with that. I'm using inside triggers and also in some Flex S-Controls for label translation.

I created a small package, you can get it at:

https://www.salesforce.com/appexchange/detail_overview.jsp?id=a0330000004JaqpAAC

Feel free to use it, and please let me know any suggestions.

Claudio