Réf. : Re: ActionForm and ArrayList

2002-10-21 Thread Arnaud . PASQUIERS

Thanks for your help.

But I have the same problem with a String[]... When I retrieve my array,
after submitting my form, its size is 0.
Do you know where I can find a real example?
(My purpose is to update an array of object (not Java objet but custom
object) via a html:form and ActionForm)





   

"Dan Tran" 

  
mail.com>cc :  

 Objet :  Re: ActionForm and ArrayList 

19/10/2002 

02:58  

Veuillez   

répondre à 

"Struts Users  

Mailing List"  

   

   





In your ActionForm define something like this

 String [] _rows;

String [] getRow() (return _rows)
void   setRow(String [] rows ) { set _rows = rows ;}


Then in your  jsp, each elements of your array use property="row", you may
want to use logic:iterate

It is the idea

-Good luck
-D
- Original Message -
From: <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, October 18, 2002 6:34 AM
Subject: ActionForm and ArrayList


>
>
> Hello,
>
>
> I have an ActionForm containing an attribute which type is an ArrayList.
> In my action "EditAction" where I prepare data for the form all is ok. I
> have the right number of elements in my ArrayList when the form is
> displayed in my JSP page.
>
> But  in my "SaveAction" called when the form is submited, when I try to
> retrieve the data from my ActionForm I have no element in my ArrayList.
> However in the other attribute (String type) of the form, I have the
right
> data.
> Why??
>
> Thanks,
> Arno
>
>
>
>
> --
> 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>






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




Re: ActionForm and ArrayList

2002-10-18 Thread Dan Tran
In your ActionForm define something like this

 String [] _rows;

String [] getRow() (return _rows)
void   setRow(String [] rows ) { set _rows = rows ;}


Then in your  jsp, each elements of your array use property="row", you may
want to use logic:iterate

It is the idea

-Good luck
-D
- Original Message -
From: <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, October 18, 2002 6:34 AM
Subject: ActionForm and ArrayList


>
>
> Hello,
>
>
> I have an ActionForm containing an attribute which type is an ArrayList.
> In my action "EditAction" where I prepare data for the form all is ok. I
> have the right number of elements in my ArrayList when the form is
> displayed in my JSP page.
>
> But  in my "SaveAction" called when the form is submited, when I try to
> retrieve the data from my ActionForm I have no element in my ArrayList.
> However in the other attribute (String type) of the form, I have the right
> data.
> Why??
>
> Thanks,
> Arno
>
>
>
>
> --
> 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>




ActionForm and ArrayList

2002-10-18 Thread Arnaud . PASQUIERS


Hello,


I have an ActionForm containing an attribute which type is an ArrayList.
In my action "EditAction" where I prepare data for the form all is ok. I
have the right number of elements in my ArrayList when the form is
displayed in my JSP page.

But  in my "SaveAction" called when the form is submited, when I try to
retrieve the data from my ActionForm I have no element in my ArrayList.
However in the other attribute (String type) of the form, I have the right
data.
Why??

Thanks,
Arno




--
To unsubscribe, e-mail:   
For additional commands, e-mail: