i use the netbeans and want to run a servlet
i get error messages:
jpackage avax.servlet does not exist
package javax.servlet.http does not exist
how can i run the servlet i want a simple solution without using
special server's
Printable View
i use the netbeans and want to run a servlet
i get error messages:
jpackage avax.servlet does not exist
package javax.servlet.http does not exist
how can i run the servlet i want a simple solution without using
special server's
Where is that package's class definitions? Is it in a jar file?
Is that jar file on the classpath when you try to compile the program?
there are some servlet files at :
C:\Program Files\NetBeans 7.1\ide\modules\locale
C:\Program Files\NetBeans 7.1\ide\modules\ext
C:\Program Files\NetBeans 7.1\ide\modules
C:\Program Files\NetBeans 7.1\ide\update_tracking
C:\Program Files\NetBeans 7.1\ide\config\Modules
2 are xml files the other are executable jar files
i dont know what path is tuned in
You need to do some research and find out:
Where is that package's class definitions? Is it in a jar file?
Is that jar file on the classpath when you try to compile/execute the program?
Your last post does not answer any of those questions.
A servlet runs inside of a server. It expects to be called from the server and will return control to the server.Quote:
how can i run the servlet i want a simple solution without using special server's
You do not run a servlet like a desktop app.
If you want to run your servlet then you'll need a server to run it on.
ETA: Phooey...
the only way i know is to search for servlet so i did :=(:
and gave the name of thejar files,should i extract them
i dont know were to look for a path :(whew):
If you have the jar file with the missing package, you need to have that jar file available to the compiler. If you use the javac command to compile your program you would use the -cp option to tell the compiler where to find the jar file.
If you are using an IDE to do the compile, you will have to ask the IDE where to put the jar file so it can find it.
how can i do so using netbeans?
There is a section of this forum for IDEs. You could try asking there.
http://www.java-forums.org/netbeans/
Do you know anything about Java web apps?
Because I suspect you ought to be going through a tutorial...
Here's the JavaEE 6 one (I've linked directly to the Servlets bit).
i know that i might use a server to run the program after compilation , what are the steps
needed to launch a resin server ?
There's a section of the forum for servlets:
Java EE
Re-posted in Java EE > Java Servlet
http://www.java-forums.org/java-serv...g-servlet.html
Closing this thread.
db
THREAD CLOSED