Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

generate UI with binding-attribute

 
nimo frey
Ranch Hand
Posts: 580
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I want to generate a HTML-PanelGrid in JAVA:



and reference this in a JSF-Page:



but I get the following stacktrace:



What is wrong?
 
Bauke Scholtz
Ranch Hand
Posts: 2458
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by nimo frey:
and reference this in a JSF-Page:



but I get the following stacktrace:




Do you see the difference? Which one is correct? Fix it accordingly.
 
Bassam Al-Sarori
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
code:
javax.el.PropertyNotWritableException: /grid.xhtml @279,45 binding="bean.htmlPanelGrid": Illegal Syntax for Set Operation


This is because your bean class does not have a set and get method for the property htmlPanelGrid.

You should have a set and get methods (maybe setHtmlPanelGrid(HtmlPanelGrid htmlPanelGrid) and getHtmlPanelGrid()).
 
Bassam Al-Sarori
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
And the syntax in your jsf page should be binding="#{bean.htmlPanelGrid}"
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic