aspose file tools*
The moose likes Servlets and the fly likes Problem in compilation Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Servlets
Bookmark "Problem in compilation" Watch "Problem in compilation" New topic
Author

Problem in compilation

deshdeep divakar
Ranch Hand

Joined: Apr 19, 2004
Posts: 91
I have developed a servlet,problem i m facing
are 1. it is not importing the packages.

tell the appropriate method to compile nd run a servelet


"Do not be afraid of going slow, be afraid of standing still"
Saket Barve
Ranch Hand

Joined: Dec 19, 2002
Posts: 229
Deshdeep,

What is your classpath set to? How exactly are you compiling your servlet?

Regards,
Saket
Sarath Mohan
Ranch Hand

Joined: Mar 17, 2001
Posts: 213
Seems you need to keep servlet-api.jar in your classpath. This will make the class to compile. Now in oreder RUN the servlet you require a servlet container like Tomcat or JRun

Visit http://java.sun.com/products/servlet/ for more resources

Regards


Sarath Mohan
deshdeep divakar
Ranch Hand

Joined: Apr 19, 2004
Posts: 91
hi this is a problem related to compilation of the servlet program.
classpaths are set as: c:\jdk1.4\lib\dt.jar;
c:\jdk1.4\lib\htmlconverter.jar;
c:\jdk1.4\lib\tools.jar;
c:\jdk1.4\lib\servlet-api.jar;
but on compiling the servlet in command prompt by javac compiler the error is the packages of servlet and servlet.http. do not exist.
there is no problem in running applet.
Girish Babu
Greenhorn

Joined: Mar 18, 2005
Posts: 6
HI,

in your command prompt before doing javac type this and try:

set classpath=%classpath%;c:\jdk1.4\lib\servlet-api.jar;.;

then compile,

still if it is not compiling then let us knw the web-server u r planning to host your servlet on, may be someone can help you,

Girish
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Problem in compilation
 
Similar Threads
error : urgent
problem in uploading assignment
Java and C# encoding prob
com.javaranch.common
jboss deployment problem