you have written in exception what you should do... Close jsp:param in your 
jsp:forward.

"Nelson Rodrigo - LHQ" <nelson.rodr...@loadstarlk.com> napisał:

>Hi Dear
>
>I have changed my code
>%>
>                                       <jsp:forward page="/AdminActions" />
>                                   <jsp:param name="YYY" value="2009" />
>                                   <jsp:param name="MMM" value="01" />
>                                   <jsp:param name="PPP" value="/773116556/" />
>                                   </jsp:forward>
>                               
>                               <%
>                       RequestDispatcher ds = 
> request.getRequestDispatcher("AdminActions");
>                ds.forward(request, response);
>
>And getting this error
>
>Oct 7, 2010 8:19:16 AM org.apache.catalina.core.StandardWrapperValve invoke
>SEVERE: Servlet.service() for servlet jsp threw exception
>org.apache.jasper.JasperException: /LoadFiles.jsp(54,13) The jsp:param action 
>must not be used outside the jsp:include, jsp:forward, or jsp:params elements
>       at 
> org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:39)
>       at 
> org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:405)
>       at 
> org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:86)
>       at 
> org.apache.jasper.compiler.Parser.parseStandardAction(Parser.java:1254)
>       at org.apache.jasper.compiler.Parser.parseElements(Parser.java:1576)
>       at org.apache.jasper.compiler.Parser.parse(Parser.java:126)
>       at 
> org.apache.jasper.compiler.ParserController.doParse(ParserController.java:211)
>       at 
> org.apache.jasper.compiler.ParserController.parse(ParserController.java:100)
>       at org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:155)
>       at org.apache.jasper.compiler.Compiler.compile(Compiler.java:295)
>       at org.apache.jasper.compiler.Compiler.compile(Compiler.java:276)
>       at org.apache.jasper.compiler.Compiler.compile(Compiler.java:264)
>       at 
> org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:563)
>       at 
> org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:305)
>       at 
> org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
>       at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
>       at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
>       at 
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
>       at 
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
>       at 
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
>       at 
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
>       at 
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
>       at 
> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
>       at 
> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
>       at 
> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
>       at 
> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
>       at 
> org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
>       at 
> org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
>       at 
> org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
>       at 
> org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
>       at java.lang.Thread.run(Unknown Source)
>
>
>Thanks & Kind Regards,
>Nelson Rodrigo
>Executive – Software Development
>LOADSTAR (PRIVATE) LIMITED
>Sri Lanka | Tel: +94 11 483 7914 | Fax: +94 11 224 0892 | Mobile: +94 77 311 
>6556
> SAVE PAPER  - Please consider our environment before printing 
>
>
>-----Original Message-----
>From: Masimba Chingwende [mailto:masim...@voxtelecom.co.za] 
>Sent: Wednesday, October 06, 2010 7:39 PM
>To: nelson.rodr...@loadstarlk.com
>Cc: java-ee-j2ee-programming-with-passion@googlegroups.com
>Subject: Re: [java ee programming] Servlet value null
>
>
>        Try this:
>
>
>        JSP forward Syntax
>
>    <jsp:forward page={"/relativeURL/" | "<%= /expression/ %>"} />
>    /or/
>    <jsp:forward page={"/relativeURL/" | "<%=/ expression /%>"} >
>    <jsp:param name="/parameterName/"
>    value="{/parameterValue/ | <%= /expression/ %>}" />+
>    </jsp:forward> 
>
>
>        Replace the forwarding java code with the below:
>
>    <jsp:forward page="/AdminActions" />
>    <jsp:param name="YYY" value="2009" />
>    <jsp:param name="MMM" value="01" />
>    <jsp:param name="PPP" value="/773116556/" />
>    </jsp:forward>
>
>
>
>
>Nelson Rodrigo - LHQ wrote:
>>
>> Dear Friends
>>
>> In my application I have to pass parameters from jsp to servlet
>>
>> In JSP
>>
>> Im using like this
>>
>> %>
>>
>> <input type=/"hidden"/ name=/"YYY"/ value=/"2009"/ />
>>
>> <input type=/"hidden"/ name=/"MMM"/ value=/"01"/ />
>>
>> <input type=/"hidden"/ name=/"PPP"/ value=/"773116556"/ />
>>
>> <%
>>
>> RequestDispatcher ds = request.getRequestDispatcher("AdminActions");
>>
>> ds.forward(request, response);
>>
>> AdminAction is my Servlet name
>>
>> In my servlet
>>
>> I’m using like this
>>
>> String fdYear = request.getParameter("YYY");
>>
>> System./out/.println(fdYear);
>>
>> But result is null
>>
>> Please advise me where I missed or is this not possible passing 
>> parameters from jsp to servlet.
>>
>> Thanks & Kind Regards,
>>
>> Nelson Rodrigo
>> Executive – Software Development
>> *LOADSTAR (PRIVATE) LIMITED
>> *Sri Lanka | Tel: +94 11 483 7914 | Fax: +94 11 224 0892 | Mobile: +94 
>> 77 311 6556
>>
>> P *SAVE PAPER* - *Please consider our environment before printing *ü
>>
>> -- 
>> You received this message because you are subscribed to the Google
>> Groups "Java EE (J2EE) Programming with Passion!" group.
>> To post to this group, send email to
>> java-ee-j2ee-programming-with-passion@googlegroups.com
>> To unsubscribe from this group, send email to
>> java-ee-j2ee-programming-with-passion+unsubscr...@googlegroups.com
>> For more options, visit this group at
>> http://groups.google.com/group/java-ee-j2ee-programming-with-passion?hl=en?hl=en
>>  
>
>
>
>
>
>-- 
>You received this message because you are subscribed to the Google
>Groups "Java EE (J2EE) Programming with Passion!" group.
>To post to this group, send email to
>java-ee-j2ee-programming-with-passion@googlegroups.com
>To unsubscribe from this group, send email to
>java-ee-j2ee-programming-with-passion+unsubscr...@googlegroups.com
>For more options, visit this group at
>http://groups.google.com/group/java-ee-j2ee-programming-with-passion?hl=en?hl=en

-- 
Michal Kosciowski
Wysłane z Androida.

-- 
You received this message because you are subscribed to the Google
Groups "Java EE (J2EE) Programming with Passion!" group.
To post to this group, send email to
java-ee-j2ee-programming-with-passion@googlegroups.com
To unsubscribe from this group, send email to
java-ee-j2ee-programming-with-passion+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/java-ee-j2ee-programming-with-passion?hl=en?hl=en

Reply via email to