servlet problem

I am writing a servlet that uses a package to convert text to pdf. This package uses java.util.Arraylist. When i compile the servlet with the command line everything works fine; when i publish it; i always get a classnotfoundexception : arraylist.
Now in order to find a solution, i wrote it in an application, and compiled it with the command line jdk 1.2.2 on the server and run the application. Everything worked fine then, the result was perfect. Now it did not give an arraylist error.
How can i do this in a servlet; considering everything works fine in an application, why doesn't it work in a servlet ??? The classpath must be correct because i can run the application .. or not ? Eventually they both use the same package; could it be that the classpath in the environment for doesn't work for a servlet ?
I am using Java Webserver 2.0 and JDK 1.2.2; i am using the classes found at : http://allserv.rug.ac.be/~blowagie/java-pdf/; this is my classpath : C:\servlet.jar;.;c:\Software\java\collections.jar;c:\InetPub\wwwroot\lib\rugPdf020.jar;
When I add an extra jar file containing the java.util.arraylist in the classpath; i get some other strange errors (like java.lang.NoClassDefFoundError: be/ac/rug/text/pdf/PdfMediaBox at com.sun.server.security.ServletSecurity11x.inServlet(Compiled Code)); ... plz help me
tappelmaAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Ravindra76Commented:
Hi tappelma,

 It was the classpath problem.

 add the path of your ibm package in the sebsrver's path.

Best of luck.

PS:Mention environment webserver,jdb etc.
0
vladi21Commented:
I think
ur servlet engine not 1.2 compatible

maybe better use JGL?
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
heyhey_Commented:
or you can download Collections package for 1.1 from www.javasoft.com
0
Introducing Cloud Class® training courses

Tech changes fast. You can learn faster. That’s why we’re bringing professional training courses to Experts Exchange. With a subscription, you can access all the Cloud Class® courses to expand your education, prep for certifications, and get top-notch instructions.

tappelmaAuthor Commented:
Edited text of question.
0
tappelmaAuthor Commented:
Adjusted points to 200
0
tappelmaAuthor Commented:
downloading collections and adapting class_path does not work.
0
heyhey_Commented:
so what's the problem.
give us more information.

I suppose that JWS uses 1.1 JavaVM, you just have to add the collection classes to its classpath - or don't use them at all.
0
tappelmaAuthor Commented:
Edited text of question.
0
tappelmaAuthor Commented:
Thx a lot dude; i installed JRun and everything works fine nog; so i guess java web server is not jdk 1.2.2 compliant.
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Java EE

From novice to tech pro — start learning today.