Win a copy of Learn Spring Security (video course) this week in the Spring forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

jsf Datatable

 
Avik Mazunder
Ranch Hand
Posts: 39
Chrome Eclipse IDE Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Datatable


HomeBean.java



HomeDataListData.java




i am getting this error

Error Rendering View[/WebPagesAdmin/Home.xhtml]: javax.el.ELException: /WebPagesAdmin/Home.xhtml @36,59 value="#{HomeBean.list}": java.lang.NullPointerException

Please help..!
 
Tim Holloway
Saloon Keeper
Pie
Posts: 17989
47
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You cannot cache the FacesContext. The FacesContext is created and destroyed for each HTTP request. For non-JSF requests, such as requests to Servlets, the FacesContext does not exist at all.

Also, HomeBean is the name of the class The proper capitalization of the instance of that bean is "homeBean".
 
Avik Mazunder
Ranch Hand
Posts: 39
Chrome Eclipse IDE Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I resolved my problem. I carelessly forgot to initialize the arraylist.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic