commandButton « Exception « JSF Q&A

1. JSF 2.0 NullPointerException exception after submitting commandButton

After mifrating JSF from 1.2 to 2.0 I begin to receive exception after submitting commandButton:

javax.faces.FacesException: java.lang.NullPointerException at org.apache.myfaces.shared_impl.context.ExceptionHandlerImpl.wrap( at org.apache.myfaces.shared_impl.context.ExceptionHandlerImpl.handle( ...

2. Reason for commandButton error

3. JSF commandButton errors in Liferay

Hello all, If I use the standard JSF commandButton in my code like this it works: