Re: Converter trying to set String on int field

2009-05-12 Thread Richard Sayre
yre >> To: Struts Users Mailing List >> Sent: Mon, 11 May 2009 11:44 am >> Subject: Re: Converter trying to set String on int field >> >> >> >> >> >> >> >> >> >> >> After some further investigation I found that any arr

Re: Converter trying to set String on int field

2009-05-11 Thread Richard Sayre
gt;  I bet it has something to do with a null not being assignable to an int. > Chris > > > > > > > > -Original Message- > From: Richard Sayre > To: Struts Users Mailing List > Sent: Mon, 11 May 2009 11:44 am > Subject: Re: Converter trying to set St

Re: Converter trying to set String on int field

2009-05-11 Thread musomesa
I bet it has something to do with a null not being assignable to an int. Chris -Original Message- From: Richard Sayre To: Struts Users Mailing List Sent: Mon, 11 May 2009 11:44 am Subject: Re: Converter trying to set String on int field After some further

Re: Converter trying to set String on int field

2009-05-11 Thread Richard Sayre
After some further investigation I found that any array type that has no values from the form on submit will call setXXX(String). I checked the source of com.opensymphony.xwork2.util.XWorkBasicConverter and this is the first thing it does: if (value == null || toType.isAssignableFrom(value.getCla

Converter trying to set String on int field

2009-05-11 Thread Richard Sayre
I have a bunch of check boxes called userId. In my action I have int userId[] and setUserId(int[] ids) When I select a checkbox the conversion works normally. When I dont check any boxes on the form and submit, I get the following: 2009-05-11 10:54:28,606 [http-8080-6] DEBUG []: - Property: user