Hi,

I had this problem when I placed my ActionForm in the Session. I noticed that when I 
uncheck all the checkboxes, the browser would transmit no value for the checkbox 
property and so the ActionForm property would not be updated to an empty String[] as I 
had expected. 

<html:multibox property="actionItemIndicator">
   <bean:write name="defectsList" property="defectId"/>
</html:multibox>

If you uncheck all the checkboxes in your example, the request query string parameter 
"actionItemIndicator" would not be transmitted. i.e. there would be no 
"&actionItemIndicator=" in the query string. Most browsers dont transmit parameters 
when they have no values.

I worked around this problem by checking if this parameter was null, and then 
implicitly set the property to an empty String[];

eg. In the Validate Method()
...
if (httpServletRequest.getParameter("actionItemIndicator") == null) {
  actionItemIndicator = new String[] {};
}

HTH.
S.

>>> [EMAIL PROTECTED] 09/22/03 04:56PM >>>
Can anyone help???  I have the following multibox in a
dyanValidatorForm:

<logic:iterate id="defectsList" name="reviewRecordForm"
property="defectsList" indexId="i">
       <html:multibox property="actionItemIndicator">
               <bean:write name="defectsList" property="defectId"/>
       </html:multibox>
</logic:iterate>

I am having trouble unchecking the checkboxes.  Everytime I uncheck a
checkbox, hit submit, when the screen comes back the checkbox is still
checked.  When I extract, the form data from this property, the form
still indicates that the checkbox is checked even though I unchecked it
in the form....

How do I uncheck a box once it has been unchecked by the user???

Thanks in advance,

Natalie

#####################################################################################
The information contained in this message and or attachments is intended
only for the person or entity to which it is addressed and may contain
confidential and/or privileged material.  Any review, retransmission,
dissemination or other use of, or taking of any action in reliance upon,
this information by persons or entities other than the intended recipient
is prohibited. If you received this in error, please contact the sender and
delete the material from any system and destroy all copies.
#####################################################################################

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to