Namaste Rupali,
First of all, response has no such method, so you should try
request.setAttribute();
When you use response.sendRedirect(); the request's attributes are probably
reset and you would not be able to get a value for your set attribute.
However you can set your attribute in request and then use <jsp:forward> to
go to the other page. Using <jsp:forward> you can get your attribute's value
from your request object.
If nothing is working then you can simply put the desired value in session
object and then retrive it in the second page.
regards
Y
----- Original Message -----
From: Rupali Bains Goswami <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, July 11, 2000 8:51 PM
Subject: Passing paramters between two jsp files
> I know this question has been posted before and I have tried the solutions
> but somehow it doesnt work for me
>
> JSP1
>
>
> response.setAttribute("AdminName","AccountManager");
> response.sendRedirect (response.encodeRedirectURL("Success.jsp"));
>
> In success.jsp
>
> out.print ("The user is : " + request.getAttribute("AdminName"));
>
> But the error I get for JSP1 is
>
> logonadministrator.java:138: cannot resolve symbol
> probably occurred due to an error in /htdocs/login2/logonAdministrator.jsp
> line 14:
> response.setAttribute("AdminName","AccountManager");
>
> Any ideas as to why I am getting this?
> I am using weblogic 5.1
> Also I am using sendRedirect as I am unable to use the forward tag in jsp
> ... I get a NoSuchMethod error when I use
>
> <jsp:forward page = "/Success.jsp" />
>
> Thanks for the help
>
> ________________________________________________________________________
> Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com
>
>
===========================================================================
> To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
JSP-INTEREST".
> Some relevant FAQs on JSP/Servlets can be found at:
>
> http://java.sun.com/products/jsp/faq.html
> http://www.esperanto.org.nz/jsp/jspfaq.html
> http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
> http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets
===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
Some relevant FAQs on JSP/Servlets can be found at:
http://java.sun.com/products/jsp/faq.html
http://www.esperanto.org.nz/jsp/jspfaq.html
http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets