Andrew,

Have u tried compiling interface CommonFunctions?

Interfaces do not have implementation. Try having it as a class instead.

                -----Original Message-----
                From:   drew w [mailto:[EMAIL PROTECTED]]
                Sent:   Wednesday, April 25, 2001 2:35 AM
                To:     [EMAIL PROTECTED]
                Subject:        How can I pass the value of a session to an
interface

                I have a interface that I want to use to format messages.

                For example if there is an error:
                I will assign it to a session, redirect to display. On this
page, I call the
                formatting function from the interface to show the contents
of the session
                in RED.

                In my interface I write:

                import javax.http.servlet.HttpServletRequest;
                public interface CommonFunctions{
                  String Session = (String) session.getAttribute("STATUS");

                  public void ShowStatus(String Session){
                   if (Session != null){
                       out.println("<font color=red>"+Session+"</font>");
                       }
                  }
                }

                How can I pass the value of the session to the ShowStatus
function?



                Thanks,
                Andrew


_________________________________________________________________
                Get your FREE download of MSN Explorer at
http://explorer.msn.com


===========================================================================
                To unsubscribe: mailto [EMAIL PROTECTED] with body:
"signoff JSP-INTEREST".
                For digest: mailto [EMAIL PROTECTED] with body: "set
JSP-INTEREST DIGEST".
                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".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST".
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