The simplest solution to this is to use a constant (or the closest Java can
manage) for the attribute name.

Paul

> -----Original Message-----
> From: Mark Stacey [mailto:[EMAIL PROTECTED]
> Sent: 28 May 2004 13:45
> To: [EMAIL PROTECTED]
> Subject: attribute name for forward
> 
> 
> Hi,
> 
> I have a chain of actions that require the first action to 
> place a bean
> in the session for a second action to retrieve. Is it 
> possible to figure
> out in the first action the name of the attribute the second 
> action will
> search for its bean under?
> 
> for instance, instead of saying:
> 
> session.setAttribute("userForm", userForm);
> return mapping.findForward("success");
> 
> and then in the second action: 
> 
> session.getAttribute(mapping.getAttributeName())
> 
> Is there something similar to the following I can say?
> 
> session.setAttribute(mapping.findForward("success").getXXXX().
> getAttributeName(),
> userForm);
> 
> this way if the attribute of the second action changes, I 
> won't have to
> change the code for the first action
> 
> thanks
> 
> Mark
> Mark Stacey
> 
> I'm using Vodafone Mail - to get your free mobile email 
> account go to http://www.vodafone.ie
> Use of Vodafone Mail is subject to Terms and Conditions  
http://www.vodafone.ie/terms/website




---------------------------------------------------------------------
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