JSF Tough Question

L

listsubscriber

I am trying to give users a list of checkboxes beside a list of file
input boxes. I want the file input boxes to remain disabled until the
user clicks on the checkbox I have coupled with the input box. Is
there a 'simple' way of accomplishing this task in JSF?

Currently, I'm investigating ValueChangeListener and ActionListener,
but I didn't want to waste too much time on this if it's not possible
without writing custom components.

I'm new to JSF and so far, nothing has been simple.
Thanks for your help.
 
K

klynn47

You might also investigate ItemListener and attach it to the checkbox.
The ItemListener interface contains the method
itemStateChanged(ItemEvent e) , and there is a method available to
ItemEvent objects called getStateChange() that you can compare to
ItemEvent.SELECTED and ItemEvent.DESELECTED to determine what the event
was.
 
L

listsubscriber

I went through all the JSF tags and I didn't see an ItemListener class.
I see it in the AWT stuff, but not in JSF. Do you have a pure JSF
solution?

Thanks.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,755
Messages
2,569,535
Members
45,007
Latest member
obedient dusk

Latest Threads

Top