Ezeilo, What are you exactly trying to do? Call a method in another servlet? Invoke a doGet or doPost method in another servlet? If you are trying to do the latter and the other servlet is in the same web application, you should forward the request to the other servlet. You will need to do something like this:
String forwardToURL = "/servlets/someServlet"; ServletContext sc = getServletContext(); sc.getRequestDispatcher(forwardToURL).forward(request,response); If you just want to call a method, you would do it just like you would if you want to invoke any other class's method. Regards, Richard At 06:03 PM 4/18/2002 +0200, you wrote: >Hi all, >Can somebody show me how to call a servlet from the doPost method of >another ? > >Uch > >___________________________________________________________________________ >To unsubscribe, send email to [EMAIL PROTECTED] and include in the body >of the message "signoff SERVLET-INTEREST". > >Archives: http://archives.java.sun.com/archives/servlet-interest.html >Resources: http://java.sun.com/products/servlet/external-resources.html >LISTSERV Help: http://www.lsoft.com/manuals/user/user.html ___________________________________________________________________________ To unsubscribe, send email to [EMAIL PROTECTED] and include in the body of the message "signoff SERVLET-INTEREST". Archives: http://archives.java.sun.com/archives/servlet-interest.html Resources: http://java.sun.com/products/servlet/external-resources.html LISTSERV Help: http://www.lsoft.com/manuals/user/user.html
