I've moved my Java stuff to a new Windows 10 machine, using jdk1.8.0_291. I've installed C:\xampp through which I'm using Tomcat.
My problem is that I can't get the main programs to compile.
The header lines are:
import javax.servlet.*;
import javax.servlet.http.*;
import java.io.*;
import java.util.*;
public class AddressServlet extends HttpServlet {
and I get the error: "javax.servlet does not exist"
Elsewhere, I've seen that javax.servlet is in servlet-api.jar in the tomcat/lib folder. I've tried adding this to the CLASSPATH variable as C:\xampp\tomcat\lib\servlet-api.jar but it didn't work. I've even copied the jar file into the same folder as the code, but the error persists.
Does anybody know what I'm doing wrong? Many thanks.
It's all ended happily! I just needed a reboot.