V.A. Kozhevnykov
 I have try it on Tomcat3.1+win98+jdk1.2.2,but it produce errors as follows.
Error: 500
Location: /website/index/file/jsp/function.jsp
Internal Servlet Error:

org.apache.jasper.JasperException: Unable to compile class for 
JSPC:\tomcat\work\localhost_8080\_0002fwebsite_0002findex_0002ffile_0002fjsp_0002ffunction_0002ejspfunction_jsp_1.java:26:
 Undefined variable or class name: out
               out.println("We are do something in the Function!");
               ^
1 error

        at org.apache.jasper.compiler.Compiler.compile(Compiler.java, Compiled Code)
        at org.apache.jasper.runtime.JspServlet.loadJSP(JspServlet.java:413)
        at 
org.apache.jasper.runtime.JspServlet$JspServletWrapper.loadIfNecessary(JspServlet.java:149)
        at 
org.apache.jasper.runtime.JspServlet$JspServletWrapper.service(JspServlet.java:161)
        at org.apache.jasper.runtime.JspServlet.serviceJspFile(JspServlet.java:261)
        at org.apache.jasper.runtime.JspServlet.service(JspServlet.java, Compiled Code)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
        at org.apache.tomcat.core.ServletWrapper.handleRequest(ServletWrapper.java, 
Compiled Code)
        at org.apache.tomcat.core.ContextManager.service(ContextManager.java:559)
        at 
org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpConnectionHandler.java,
 Compiled Code)
        at org.apache.tomcat.service.TcpConnectionThread.run(SimpleTcpEndpoint.java, 
Compiled Code)
        at java.lang.Thread.run(Thread.java, Compiled Code)

 after i revised out.println to System.out.println,it passes,but it has no display of 
the function.



�� 00-11-3 14:46:00 �����
>Hi
>
>>hi all,
>>how do u define and call a function in a jsp page..
>>Please if possible send a sample code.
>>Nova
>
><%
>// Main page processing part
>
>        out.println("now call Do SMTHG");
>        doSMTNG();
>
>%>
>
>
><%!
>// Definition Part
>
>public(private) void doSMTNG()
>{
>        out.println("in Do SMTHG");
>}
>
>%>
>
>
>good luck
>Valik
>
>_________________________________________________________
>Do You Yahoo!?
>Get your free @yahoo.com address at http://mail.yahoo.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

                    ��
��

            ycd
            [EMAIL PROTECTED]

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

Reply via email to