Question

I've been trying to programmatically insert composite components into an UIPanel. For this I tried to use BalusC's includeCompositeComponent method.

Only I have a NullPointerException on the first application.createComponent. It points to :

com.sun.faces.application.view.FaceletViewHandlingStrategy.getComponentMetadata(FaceletViewHandlingStrategy.java:237) [jsf-impl-2.1.25.jar:2.1.25]

Apparently there's no FaceletFactory in my FacesContext. I've looked in Debug mode into facesContext.getAttributes() and seen none.

Did I miss something ?

I use :

  • JBoss 7.1
  • jsf-impl-2.1.25
  • RichFaces-4.3.4
Was it helpful?

Solution

My problem was the phase in which I was trying to insert my components. It was on postInvokeAction.

By doing it in postAddToView, I don't have the problem.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top