You really want to stick the data in session scope - that is what it is for.

Request scope really won't help - anything in there will have gone out of
scope immediately after the page is rendered for the user.

I'd *seriously* question why you aren't supposed to be using session scope.
Can you give us an idea why you are being asked to avoid it's use?

If you can't use session scope then I think the only place you can store the
data is the rendered html. You could use hidden input fields to store the
data - these values will then be provided to the action then next time it is
called. I think you should look at indexed properties - I haven't used them
myself.

Paul

> -----Original Message-----
> From: Brian Ivey [mailto:[EMAIL PROTECTED]
> Sent: 09 February 2004 17:44
> To: Struts - List
> Subject: Passing an ArrayList
> 
> 
> I'm working on an application that prompts a user to enter 
> data into 4 text
> fields.  The user then clicks on a button to submit these to 
> an Action.
> These 4 values are used to create an object that is added to 
> an ArrayList.
> The page used for data entry is refreshed with the just entered values
> appearing as a row in a table.  The user may do this as many 
> times as they
> wish.
> 
> My problem is that the ArrayList is recreated every time the Action is
> called.  I understand that this a characteristic of the 
> transient nature of
> Actions.  Can anyone make any recommendations on possible 
> ways to preserve
> this ArrayList between calls to the Action.  I'm betting that 
> this could be
> resolved by stashing the ArrayList into the request as an attribute or
> something similar, but would like some commentary on this 
> issue.  BTW, the
> project this application is for mandates only request scope be used.
> 
> Thanks,
> Brian Ivey
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 


**************************************
Axios Email Confidentiality Footer
Privileged/Confidential Information may be contained in this message. If you are not 
the addressee indicated in this message (or responsible for delivery of the message to 
such person), you may not copy or deliver this message to anyone. In such case, you 
should destroy this message, and notify us immediately. If you or your employer does 
not consent to Internet email messages of this kind, please advise us immediately. 
Opinions, conclusions and other information expressed in this message are not given or 
endorsed by my Company or employer unless otherwise indicated by an authorised 
representative independent of this message.
WARNING:
While Axios Systems Ltd takes steps to prevent computer viruses from being transmitted 
via electronic mail attachments we cannot guarantee that attachments do not contain 
computer virus code.  You are therefore strongly advised to undertake anti virus 
checks prior to accessing the attachment to this electronic mail.  Axios Systems Ltd 
grants no warranties regarding performance use or quality of any attachment and 
undertakes no liability for loss or damage howsoever caused.


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

Reply via email to