wood burning stoves 2.0*
The moose likes JSF and the fly likes disable PropertyNotFoundException and return key Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » JSF
Bookmark "disable PropertyNotFoundException and return key" Watch "disable PropertyNotFoundException and return key" New topic

disable PropertyNotFoundException and return key

Hawe Kerck

Joined: Apr 22, 2011
Posts: 2
Hi everybody,

I've a JSF 2.0 (Primefaces 2.2.1 / Myfaces 2.0.3) , Spring (3.0.2Release) Project which should work with messages.properties.
It's even no problem to read out the properties and display them from my beans or the xhtml pages. But the problem is, if a key is not defined for a language I got an PropertyNotFoundException and the page will not be displayed anymore. Is there a posibility to display the key (I've one worked on a project with JSF 1.2 but I can't get the sorce anymore) where properties that haven't been written to the messages.properties are displayed as ???key.notfound???

Is there a possibility to get this behaviour with Myfaces and Spring 3.0.2Release?

Thank for your help

Hawe Kerck

Joined: Apr 22, 2011
Posts: 2
Fixed it on my own using ReloadableResourceBundleMessageSource

add this to your spring-context

put your own SpringElResover into your faces-config

finally use your MySpringBeanFacesELResolver (which I found on forum.springsource.org)

I agree. Here's the link: http://aspose.com/file-tools
subject: disable PropertyNotFoundException and return key
Similar Threads
JSF 2.0 - PropertyNotFoundException
PropertyNotFoundException couldn't be resolved
PropertyNotFoundException exception
[JSF] PropertyNotFoundException: Can't instantiate class