8 Replies Latest reply on Sep 7, 2007 8:16 AM by yohann Normandin

    Exception with SelectManyCheckbox

    yohann Normandin Newbie

      Hello !!!!!!

      I have a list of report(already persist in database), and I want to display them on a jsf page with selectManyCheckbox.But when I want to acces to the page I have this exception :

      Exception during request processing: javax.servlet.ServletException: Expected a child component type of UISelectItem/UISelectItems for component type javax.faces.SelectMany(j_id28). Found null.

      My jsf page :

      <html xmlns="http://www.w3.org/1999/xhtml"
       <ui:composition template="templates/client.xhtml">
       <ui:define name="servicesclients">
       <h:selectManyCheckbox value="#{reports}">
       <f:selectItems itemValue="#{reporte}" var="rep" itemLabel="#{rep.descReport}"/>

      My entity :

      public class Report implements Serializable {
       @GeneratedValue(strategy = GenerationType.AUTO)
       private Long reportId;
       private String repName;
       private String descReport;
       *Creates the foreign key in relation to the category table
       @OneToMany (mappedBy = "reportId")
       private List<Category> categories;
       *Creates the foreign key in relation to the ContactReportBinder table
       @JoinColumn (name = "binderId_fk")
       private ContactReportBinder binderId;
       /** Creates a new instance of Report */
       public Report() {
      Then Getters and setters

      and My Bean :

      public class ReportManager implements com.pingwy.web.front.ReportManagerLocal, Serializable {
       * Creates a new instance of ReportManager
       private EntityManager em;
       @DataModel @Out(required = false) private List<Report> reports;
       @DataModelSelection @Out(required = false) @In(required = false) SelectItem reporte;
       public List<Report> getReports() {
       return em.createQuery("select r from Report r").getResultList();
       public void setReports(List<Report> reports) {
       this.reports = reports;
       public SelectItem getReporte() {
       return reporte;

      Thanks for your help in advance.