wood burning stoves*
The moose likes JSP and the fly likes jsp-vector Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » JSP
Bookmark "jsp-vector" Watch "jsp-vector" New topic
Author

jsp-vector

Duray Rajesh
Greenhorn

Joined: Jun 16, 2006
Posts: 12
hi,
How can i forward vector from one jsp to another?
Christophe Verré
Sheriff

Joined: Nov 24, 2005
Posts: 14687
    
  16

Putting it in the request before forwarding, using request.setAttribute ?


[My Blog]
All roads lead to JavaRanch
Bk Jacky
Ranch Hand

Joined: Jun 11, 2005
Posts: 74
hi
There is number of ways you can forward vector from one jsp page to another.check your case from following statemets:

If you want your vector scope is limied to request then use
request.setAttribute("name",vector object);
then use request dispatcher to forward the request
and use
request.getAttribute("name");
If you want your vector available for whole session then use

session.setAttribute("name",vector object);

Get this vector in your required jsp page by

session.getAttribute("name");

If you want your vector available for whole web-app then use

getSerletContext().setAttribute("name",vector object);

Get this vector in your required jsp page by

getSerletContext().session.getAttribute("name");

Bhupinder Singh
SCJP1.4
Preparing SCWCD

Nothing is impossible in this World


SCJP1.4<br />SCWCD1.5<br />"Nothing is impossible"
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: jsp-vector
 
Similar Threads
Value in dropdown from servlet
How to send large data from servlet to jsp
parameter from jsp to javascript function?
Regarding about sending request attributue from jsp to servlet
vector