This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Servlets and the fly likes Servlet Problem Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "Servlet Problem" Watch "Servlet Problem" New topic

Servlet Problem

R Sugan
Ranch Hand

Joined: Mar 13, 2009
Posts: 48
I need to run my Servlet program continuously and without using HTTP parameters so i am using load on start up function and am include my Servlet class name into web.XML. But i can't able to open Apache-tomcat browser.Please give me any solution to solve this

Following is my code:

This is my servlet code

Ankit Garg

Joined: Aug 03, 2008
Posts: 9291

Suganya is that the complete code for the servlet?? There is no doGet or doPost method so you won't be able to access the servlet from an HTTP request i.e. through a browser. If that is not the complete code, then please provide the complete code...

SCJP 6 | SCWCD 5 | Javaranch SCJP FAQ | SCWCD Links
Bauke Scholtz
Ranch Hand

Joined: Oct 08, 2006
Posts: 2458
There the HttpServlet is not for.
Implement ServletContextListener.
I agree. Here's the link:
subject: Servlet Problem
Similar Threads
How to use an event
problem in servlet
running servlet after the browser is closed
Refresh a Servlet page
datas storing twice from servlet to mysql database