Hi minh,
ChartDirector for JSP/Java includes sample code for both desktop applications (in Java SWING) and web applications (in JSP). The SWING sample code are all clickable. When you click on it, it will pop up a message box displaying the item that you have picked. For the JSP sample code, when the mouse is over the slice, it will pop up a box displaying more information about the slice. You can make it clickable by providing a URL in the getHTMLImageMap method. For example, in the "Simple Pie Chart" sample code, instead of using
String imageMap1 = c.getHTMLImageMap("", "", "title='{label}: US${value}K ({percent}%)'");
you may use:
String imageMap1 = c.getHTMLImageMap("aaa.jsp", "", "title='{label}: US${value}K ({percent}%)'");
In this case, when the user clicks on a slice in the pie chart, it will jump to the URL "aaa.jsp". The slice acts like a link. There will be query parameters included so that the script "aaa.jsp" can know which slice has been clicked.
There is also a complete example in the "Clickable Charts" section of the ChartDirector for JSP/Java documentation:
http://www.advsofteng.com/doc/cdjava.htm#simpleclickable.htm
Hope this can help.
Regards
Peter Kwan |