Hai friends , I have a program in servelet it displays an error during compilation,the error is, cz\samba\projects\arc\analyse\AnalyseServlet.java:34: cannot access cz.samba.pro jects.arc.analyse.sk.skultety.websitexml.WebPageConfig bad class file: .\cz\samba\projects\arc\analyse\sk\skultety\websitexml\WebPageCo nfig.class class file contains wrong class: sk.skultety.websitexml.WebPageConfig Please remove or make sure it appears in the correct subdirectory of the classpa th. private WebPageConfig webPageConfig; ^ 1 error But the class is there in the correct path. Please help me its so urgent
I think the problem is a little bit more than that. You have the class sk.skultety.websitexml.WebPageConfig It appears to exist in the directory '.\cz\samba\projects\arc\analyse\' ie a directory relative to somewhere. The directory '.' is included on your classpath. When you import it, you are trying to import the class as cz.samba.pro jects.arc.analyse.sk.skultety.websitexml.WebPageConfig This is not the fuly qualified class name. (see above) Firstly you need to make sure the directory '.\cz\samba\projects\arc\analyse\' is on your classpath, then refer to class by its correct name. I think. It's all very confusing. Another point that needs to be made is that the two examples given above are not the correct way to add classes to the classpath for web applications. You may be better off putting the source in the web-inf\classes directory of the web server. Dave
Just take some time out and learn how to use ANT to build servlet projects. You will be glad you did. You can completely avoid setting environment variables for specific projects. Bill ------------ Moose bites can be very painful!