Correct.  Just to expand on it a bit for Puneet... the request that you
set the attribute on is the request for resultsPage.jsp.  That is the
final resource the server returns for that request.  Once it is
returned, that request is destroyed.  A link on that page represents a
whole new request, hence your object is not present in it.

You can set it your object in session as stated, which would make it
available to any request made within that session.  That's about the
easiest answer.

Alternatively, if you serialize it in some way, you can put that value
in a hidden form field as suggested.  Then, when that form is submitted,
you will be able to reconstitute the object.  I'm pretty sure the
built-in object serialization mechanism will not work here thought
because it generates a binary representation of the object, and hence
may not be representable as a textual form value.  But, you can write
your own serialization implementation that generates just plain text,
then just have a static reconstitute() method on your object that
returns a new object with the values set.  Same basic thing.

Frank


thanks both of you. My concepts were screwed up which have been corrected.
Anyway, as for the solution i used a hidden field to pass on the id to
another action which generated the new page. I did not want the id floating
around in the url so stopped short of just using a link. Dont know how good
the solution is, but for now it works. :-)

THanks

--
Puneet

Reply via email to