<p>I am setting up my Java EE version of Eclipse to compile Servlets. I have the problem where Eclipse says "HttpServlet" cannot be resolved because it can't find the Java EE jar files.</p>

<p>I am using Windows XP. I already have Tomcat 6.0 up and running. I think the easiest solution would be to link to the servlet-api.jar file in the Tomcat installation.</p>

<p>I added it to the Windows CLASSPATH environment variable. Now it looks like this:
.;C:\Program Files\Java\jre1.6.0_04\lib\ext\QTJava.zip;C:\Program Files\Apache Software Foundation\Tomcat 6.0\lib\servlet-api.jar</p>

<p>That didn't work. Am I doing something wrong?</p>

<p>What is the best solution?</p>

a few thing to check:
Did you create your project as a "Dynamic Web Project" (via New->Project...->Web->Dynamic Web Project) ?
you should have a Web App Librairies directory which does contains:
Web App Librairies
JRE System Library
Apache Tomcat vx.y
Did you select a server in "Window -> Preferences... -> Server -> Installed Runtimes" ?
Do you have a TOMCAT_HOME in Prefereces -> Java -> Build Path -> Classpath variable referring to the home directory of your tomcat installation ? Try to add it to your project classpath.