Latest Tutorials| Questions and Answers|Ask Questions?|Site Map



Home Answers Viewqa Java3D When we click on a slice of a pie chart created using jfree chart it should redirect to another jsp showing the slice information on which i clicked
Login         

View Questions and Answers by Category

Advertisements


 
Have Programming Question? Ask it here!
 
 
 


naresh malempati
When we click on a slice of a pie chart created using jfree chart it should redirect to another jsp showing the slice information on which i clicked
0 Answer(s)      2 years and a month ago
Posted in : Java3D


Hi i have created a pie chart using jfree chart in jsp and its working fine.

Any one help me for the following scenario:

If we click on any slice of a pie chart it should redirect to another jsp showing that particular slice information.

the following is the code i used forcreating pie chart.

<%@page contentType="text/html" pageEncoding="UTF-8"%>

<%@ page import="java.awt.*" %> <%@ page import="java.io.*" %> <%@ page import="org.jfree.chart.*" %> <%@ page import="org.jfree.chart.entity.*" %> <%@ page import ="org.jfree.data.general.*"%> <% final DefaultPieDataset data = new DefaultPieDataset(); data.setValue("One", new Double(43.2)); data.setValue("Two", new Double(10.0)); data.setValue("Three", new Double(27.5)); data.setValue("Four", new Double(17.5)); data.setValue("Five", new Double(11.0)); data.setValue("Six", new Double(19.4));

JFreeChart chart = ChartFactory.createPieChart ("Pie Chart ", data, true, true, false);

try { final ChartRenderingInfo info = new ChartRenderingInfo(new StandardEntityCollection()); final File file1 = new File("../webapps/jspchart/ web/piechart.png"); ChartUtilities.saveChartAsPNG( file1, chart, 600, 400, info); } catch (Exception e) { out.println(e); } %> JSP Page <IMG SRC="piechart.png" WIDTH="600" HEIGHT="400" BORDER="0" USEMAP="#chart">


Advertisement
View Answers

Related Tutorials/Questions & Answers:
Create a Pie Chart in jsp Page using JFree Chart
Create a Pie Chart in jsp Page using JFree Chart  Hello Sir I followed ur tutorial on "CREATE A PIE CHART IN JSP PAGE USING JFREE CHART... the pie chart report and after that save it to the desired location.Kindly help me
Pie chart Jfree create error
Pie chart Jfree create error  hi........... thanks 4 ur help but when i am using the code which has a import file import org.jfree.chart.*; its... to resolve this problem????////// i am using jdk1.5 to run the program plz
Advertisements
Pie chart on jsp
Pie chart on jsp  how can i create a pie chart on a jsp page using... that creates a pie chart using JFreechart api and takes the value from...; For the above code, we have created a database table named result which consists of two
jfree chart
jfree chart  i need donut chart using jfree
pie chart
pie chart  how to create pie chart using struts2
Pie chart
Pie chart  hi................. In my project i want to create a pie-chart by taking values at run time. As want to display it in pie chart form the result. Can u tell me the code for it. I am using 4 my project Java swings
3d pie chart - Java3D
3d pie chart  Dear Sir, i want to create 3d pie chart using jsp, i have some code for 2d pie chart in jsp and 3d pie chart in applet. for 2d pie... for creating 3d pie chart but its showing error. i used following code
Create a pie chart in jsp page using JFreeChart
Create a pie chart in jsp page using JFreeChart... to create a pie chart in jsp page using JFreeChart. Code given below creates a simple pie chart for given values. In the code given below we have extended class
display combination of a stacked area chart and line chart in one iframe using jfree - JSP-Servlet
display combination of a stacked area chart and line chart in one iframe using jfree  hello i have a problem related to jfree chart, i want.... i m using struts1.1 servlet, jsp. please provide me the help or path
Dynamin Jfree chart in jsp---error
Dynamin Jfree chart in jsp---error   While compiling this CODE...); JFreeChart chart = ChartFactory .createBarChart3D( "Stock Update", "runs...); try { ChartUtilities.saveChartAsJPEG(new File("c:\\chart.jpg"), chart
Pie Chart
; In this section we are providing you an example to create a Pie Chart. Description of Example   For creating a Pie Chart we use PieDataset... a dataset for a pie chart we have to create an object of DefaultPieDataSet type
JFree 3D Bar Chart not displaying in JSP - Java3D
JFree 3D Bar Chart not displaying in JSP  Hi I am trying to run JFree 3D bar chart written in your site under link: http://www.roseindia.net... is not coming up i.e. not saved in the local directory. I have changed the PNG directory
pie chart
pie chart  hii..how to display data from database and show it in piechart according to different data that is present in database..plzz help
How to draw pie chart in J2ME
How to draw pie chart in J2ME  Hi, I'm developing a program using J2ME and I want to draw a pie chart but it seems J2ME language hasn't available chart component like JFreeChart in Java! could any one help me how can I draw a pie
JFREE chart - Java Beginners
JFREE chart  how can i get the latest save image of my action class.....thanks,i want my chart to display dynamically from my database  Hi.... JSP Page We hope that this code
JFree chart package error
JFree chart package error  hi, I had asked u abt the jfree chart... of import file is not there. I want to ask that how to add the import files which are not there in the package which is being downloaded? i have downloaded
Create pie chart
Create pie chart  hi............. In my project i want to create a pie chart to display the result. i require a very simple code in java swings were i can edit the code and put my values... so plz help me
3D Pie Chart
; In this section we are providing you an example to create a 3D Pie Chart. Description of Program :    For creating a 3D Pie Chart we use.... Description of Code : For defining a dataset for a 3D Pie Chart we have to create
Jfree chart problem - Swing AWT
Jfree chart problem  hello i have a problem related to jfree chart i have some data and i want to display data in two different chart stacked... of stacked areachart and line chart in one frame. I want to display hybrid graph
Pie Chart - Java Beginners
Pie Chart  How to Draw a Pie chart using graphics in java  Hi friend, I am going to post complete running code. import java.awt.... ChartPanel(values, names, "Simple Pie Chart")); WindowListener wndCloser = new
Create Pie Chart using database values
Create Pie Chart using database values Java provides JFreeChart library which... a pie chart by retrieving the values from the database. Here is the code... which enables the programmer to create charts very easily. You have already learned
hybrid graph (jfree chart) - Swing AWT
hybrid graph (jfree chart)  hello i have a problem related to jfree chart.I want to display hybrid graph (Stacked Area and Line ).combination... and explain in details For more information on chart visit to : http
Bar Chart in JSP - JSP-Servlet
Bar Chart in JSP  Hi I am creating Bar chart using Jfree charts in JSP. Please advise me how to customize it. Like controlling the colors, width for each bar, showing values above the bar .  hi friend, Use
PHP GD Pie Chart
); for ($i = 160; $i > 150; $i--) { imagefilledarc($image, 150, $i, 200, 100, 0, 45, $darknavy, IMG_ARC_PIE); imagefilledarc($image, 150, $i, 200, 100, 45, 75 , $darkgray, IMG_ARC_PIE); imagefilledarc($image, 150, $i
Draw Pie Chart
Draw Pie Chart       This Java Pie Chart example is going to show you how to draw Pie Charts in Java. This Java Pie Chart example is drawing a pie chart to show
JavaScript array slice
into this example code we have created an array of length five and we have applied slice... the selection and should be a number and it is must in the slice() method. EndIndex... JavaScript array slice     
pie chart flex and sum from hql request
pie chart flex and sum from hql request  hi, i work with flex... to show the result in the pie shart but the probleme is i don't have a field to define when i use the shut.plz help me
i want to show timeline chart for three year in chart..
i want to show timeline chart for three year in chart..  I am using Jfree chart library to display chart in web pages. i want to show three year data in chart in 3 lines for three year in same chart. i am able to show
Bar Chart using JSP and tooltip to be implemented
Bar Chart using JSP and tooltip to be implemented  Hi Deepak, I have generated a bar chart in JSP using JFreeCharts but I could not get the tool tip for that. Please any one suggest me how to do that or provide some code. Help
create bar chart in jsp using msaccess database
create bar chart in jsp using msaccess database  thanks for reply, that code i can use but i get the below error, pls help me message... button. 5)Your DSN will get created. 6) Restart your server and run given jsp code
Chart & Graphs Tutorials in Java
Category Plot chart using JFreeChart.   Create a pie chart in jsp page using JFreeChart This Example shows you how to create a pie chart in jsp.... The Following examples have been created by using JFreeChart API's. Pie
 

 

 

DMCA.com