Win a copy of Think Java: How to Think Like a Computer Scientist this week in the Java in General forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

setPropertyActionListener throwing "Illegal Syntax for Set Operation"

 
Sam Mc Kee
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I've got a commandlink within a ui:repeat that is supposed to set some values on a bean. The loop looks like this.



The first three setPropertyActionListeners work just fine (they set booleans on the timecardBean) but the timecardBean year and month, not matter which one I put first throws an error that says " target="timecardBean.year": Illegal Syntax for Set Operation."

This is the set operation in TimecardBean:



That's it, nothing more to it. The getMonth() and getYear() methods on the Timecard (the variable for the ui:repeat) also return integers.

I've googled this to death and am at wit's end. Any advice would be greatly appreciated.

Thanks!
 
Tim Holloway
Saloon Keeper
Pie
Posts: 18152
52
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
View Definition Language is not a procedural programming language. It's a template for a web page (View).

Before worrying about why it doesn't work, consider why you tried to design what should be a specification as though it was a program. View-based looping and parameter setting and other such programming constructs are rarely needed in JSF. Misuse of them, however, results in more complex, less reliable code than what you'd get if you didn't try to force JSF down paths for which is wasn't designed.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic