Re: Servlet produces a java.lang.NoSuchMethodError (at HttpServlet.setAttribute(String, Object) when viewed through a browser but compiles fine.
Thursday, April 12, 2001 08:01 AM
My guess is that you are using a newer version of the JDK to compile, and an old version to run the servlets. The method "setAttribute" replaces an older method, "putValue". Check the JRE version that you're using to run the servlets. (If you're not sure, get a version of snoop servlet, which usually comes with the servlet SDK, and call it from a browser; it will tell you.)