I suppose you have several checkboxes corresponding to the List of objects.

Are you using the <html:multibox> tag?  If not, you should.  The Struts framework will 
save the selected values in a String array that you provide.  The value stored will be 
the value of the checkbox.  For example

<html:multibox property="selectedItems" value="foo"/>

if the checkbox is selected the array will include the string 'foo'.

Have you looked at the html-multibox.jsp that is part of the struts-exercise-taglib 
application that ships with Struts?

Sri

-----Original Message-----
From: Kishore, Sahu [mailto:kishores@;tanning.com] 
Sent: Thursday, October 24, 2002 3:19 AM
To: '[EMAIL PROTECTED]'
Subject: Checkbox problem



In my form bean I have an attribute which is an Arraylist of  objects who in turn 
contain many attributes one of which is a string representing 
a checkbox of my screen.

Problem :

        -When I check anyof the check boxes and proceed to the next screens and 
comeback again to the screen having the check boxes to uncheck 
          some of the checkboxes which I have checked earlier then it's not getting 
updated in the form bean.
         I have taken the default value of the attribute representing the checkbox as 
false. And when it gets checked I'm making it to True.

So any solution?


Thanks 
Kishor


--
To unsubscribe, e-mail:   <mailto:struts-user-unsubscribe@;jakarta.apache.org>
For additional commands, e-mail: <mailto:struts-user-help@;jakarta.apache.org>


--
To unsubscribe, e-mail:   <mailto:struts-user-unsubscribe@;jakarta.apache.org>
For additional commands, e-mail: <mailto:struts-user-help@;jakarta.apache.org>

Reply via email to