Granny's Programming Pearls
"inside of every large program is a small program struggling to get out"
The moose likes JSF and the fly likes Changing the value of a rich:comboBox Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » JSF
Bookmark "Changing the value of a rich:comboBox" Watch "Changing the value of a rich:comboBox" New topic

Changing the value of a rich:comboBox

daphna deutsch

Joined: Nov 17, 2005
Posts: 21

I'm quite new to JSF, so maybe my question is really simple.

I’m using a table to display list of data. When clicking on one of the row, I display an hidden div that contains rich:comboBox.
I want that the value of the rich:comboBox (the one that is no selected) will be change from row to row.
So – when I display the div, using java script, I also set the value of the component.
However, this has no affect on the component…

Bauke Scholtz
Ranch Hand

Joined: Oct 08, 2006
Posts: 2458
JSF runs at the server side and produces HTML.
JS runs at the client side and intercepts on HTML DOM.

So, whenever you want to write a JS function, you should not look at the JSF source code, but look at its generated HTML output. Base your Javascript on this. The HTML element in question may not have a 'value' attribute, for example a <select> element. If you stucks in this, try a HTML/Javascript forum. The JSF code is irrelevant here.
Have you checked out Aspose?
subject: Changing the value of a rich:comboBox
It's not a secret anymore!