Calling Windward in a servlet
This is an example of how to create a servlet that uses Windward Reports. This example can be used with any app server - the specifics below are for Tomcat but most app servers work almost identically.
Tutorials
Tomcat
- To use, place the servlet directory in %TOMCAT_HOME%/webapps/WindwardReportsServlet
- In the directory %TOMCAT_HOME%/webapps/WindwardReportsServlet/WEB-INF/lib place the following jar files:
- WindwardReports.jar
- commons-codec.jar
- dom4j.jar
- iText.jar (pdf reports only)
- iTextAsian.jar (pdf reports in CJK only)
- Do not put log4j.jar in the lib directory. It must be copied to %TOMCAT_HOME%/common/lib!
- Place your WindwardReports.properties file in the WEB-INF directory (the WindwardReports.properties file in this example does not have a legitimate license key).
- Make sure you create the directory %TOMCAT_HOME%/webapps/WindwardReportsServlet/images
- Run build.bat in the WEB-INF/classes/com/windwardreports directory.
- index.html explains the rest.
- Once Tomcat is running, you can go to http://localhost:8080/ to verify that Tomcat is successfully installed and running.
The files
Running this sample
Note: You need to install Tomcat, start Tomcat, build this example, and install this example in Tomcat before the following link will work. Once you have done all that go to http://localhost:8080/WindwardReportsServlet/ and you should see the servlet.
|