cancel
Showing results for 
Search instead for 
Did you mean: 

How to read localization properties file in controller?

Former Member
0 Kudos
 
svintha
Explorer
0 Kudos

Is the issue solved ? after following the below steps ? to include the messageSource and i18nService

Former Member
0 Kudos

Thanks Sairam. Its working.

View Entire Topic
svintha
Explorer
0 Kudos

Hi can you try using this in the controller

@Resource(name = "messageSource") private MessageSource messageSource;

@Resource(name = "i18nService") private I18NService i18nService;

protected MessageSource getMessageSource() { return messageSource; } protected I18NService getI18nService() { return i18nService; }

getMessageSource().getMessage("xxx.xxx.xxx.xxx", null, getI18nService().getCurrentLocale())