That's what you have to do, as Adam said, the browser won't send the
value of unselected checkboxes. The sequence for create your form bean
are : Create, Reset, Populate, and Validate. You should override the
Reset method of the ActionForm to make sure that your form bean accept
new value from the browser.
Hope this may help. ;)
starki78 wrote:
> Hi Adam I just tried:
> public void reset(ActionMapping mapping, HttpServletRequest request) {
>   
>     multiboxvalues = new String[3];
>     multiboxvalues[0] = "";
>     multiboxvalues[1] = "";
>     multiboxvalues[2] = "";
>     
>   }
>
> And now the problem seems to be solved but to be honest I
> don't have the knowledge to understand it!
>
> Thanks for you advice!
>
>
>
>
>   
>> Browsers are only required to submit values for checkboxes when they are
>> selected. So when a box is not checked, no value is sent, so the state
>> on the server is not changed. When using session scoped objects to store
>> the value of checkboxes your processing needs to be aware of the fact
>> that values for "checkbox=off" are not sent.
>>
>> -Adam 
>>
>> -----Original Message-----
>> From: starki78 [mailto:[EMAIL PROTECTED] 
>> Sent: Thursday, June 08, 2006 11:40 AM
>> To: user
>> Subject: multibox not works when all checkboxes are unselected!
>>
>> Hi!
>>
>> I've a large problem with html:multibox.
>> I've tree checkboxes. When I choose
>> one or two or three it arrives correct
>> at the next action!
>> Only then all checkboxes are deselected
>> it remembers the state of the checkboxes that was selected before! The
>> state of the form is session in struts-config.
>> Can you help me with this problem??
>> I really don't have an idea how to solve it!
>>
>> Thanks a lot!
>>
>>
>>
>>
>>
>>
>>
>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>
>>
>> -----------------------------------------
>> The information contained in this message may be privileged,
>> confidential, and protected from disclosure. If the reader of this
>> message is not the intended recipient, or any employee or agent
>> responsible for delivering this message to the intended recipient,
>> you are hereby notified that any dissemination, distribution, or
>> copying of this communication is strictly prohibited. If you have
>> received this communication in error, please notify us immediately
>> by replying to the message and deleting it from your computer.
>>
>> Thank you. Paychex, Inc.
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>
>>
>>     
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
>   


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

Reply via email to