||Dynamically Creating PDFs in a Web Application|
|Subject:||Exception in thread "main"|
Response to: Exception in thread "main"
This means you've tried to run PDFServlet's main method by running 'java PDFServlet'.
The servlet PDFServlet can not be run directly, it must be placed inside a servlet container like Tomcat, and it must be called from your web-browser (as in http://localhost:8080/projectName/servletName ).