graph chart

Advanced Pie Chart

2D / 3D Pie Chart, version 3.2
by Sirius Computer Consultants Limited

 

Applet - Servlet Combination

One of the factors to consider when deciding between implementing the applet or servlet form of the graph is that, browsers in general do not print applets very well and the results can vary between browser makes and versions. The servlet however returns the graph image to the browser in GIF format and as such will print consistently without any problems across all browser makes and versions.

Another factor to consider when deciding to implement the applet or servlet is whether the interactive features of the applet are required (mouseover pop-ups and mouseclick URL functionality). In the servlet form, the graph is returned to the browser as a GIF image and as such the interactive features of the applet are not available.

This example demonstrates how to implement the applet and servlet together so that all the interactive features of the applet are presented to the user and also giving the user the option of printing the page containing the graph.

On this first page we implement the applet ( which acquires both the configuration and graph data from data files). Clicking on the note at the foot of the graph will bring up an almost identical page which contains the servlet implementation which is universally printable.

 

 

The configuration data is acquired from the text file pieprops.txt (click here to view)
and the graph data is acquired from the text file piedata.txt (click here to view).

and here is the HTML code,

<img src="http://localhost:8080/servlet/PiechartServlet?
config=http://www.jpowered.com/pie_chart/Examples/pieprops.txt&
data=http://www.jpowered.com/pie_chart/Examples/piedata.txt" width="600" height="420">

For a full explanation of and range of values for the above parameters please see the Documentation.

Note: If you are using the evaluation version then in the applet a pop-up window will appear upon the startup and an evaluation message will be incorporated by the servlet. Both these features have been removed from the licensed version. Licensing information can be found at

 

Examples

Contents

Introduction

Applet Examples
Servlet Examples
Applet - Servlet Combination

Licensing and Purchasing Options

Documentation

Further Information and Support

More Graph and Chart Functions