Hi,
I am using Spring + JPA + JSF + RichFaces integration with oracle as database server.
In my jsf page i have the following code:
I have to populate it when this page gets loaded. Following is my Java Code:Code:<h:selectOneMenu id="serviceId" value="#callListBean.callListVO.selectedPatient}"> <f:selectItems value="#{callListBean.callListVO.patientList}" /> </h:selectOneMenu>
but when the above code executed, it gives the NullPointerException. I know the reason that when constructor executes, 'service' is null as spring will inject this after the constructor's execution.Code:class SomeClass() { // spring will inject this service private SomeSpringInjectedService service; private SomePOJO pojo; private List patientList // constructor public SomeClass() { patientList = service.getResult(); } public String populate() { } }
Please help me how to populate my dropdown menu on page load.
thanks


Reply With Quote
