ANN: JFreeChart 0.9.6

A new version of JFreeChart, a popular free chart library for Java, has been posted at:
http://www.object-refinery.com/jfreechart/index.html
This release fixes bugs from the recent 0.9.5 release. JFreeChart is free software under the terms of the GNU LGPL.
Regards,
Dave Gilbert
JFreeChart Project Leader

These forums are not for advertisement purposes.
Please use them to get help or to help Java
programmers. Thanks.
Berk Can CelebisoyI believe that I am helping Java programmers by drawing their attention to a commercial quality, fully open source chart library based on the Java 2D APIs. You can download the code, run it, study it, modify it, even redistribute it under the terms of the GNU LGPL. And all you have to pay is...nothing.
Regards,
Dave Gilbert
JFreeChart Project Leader
P.S. You can have the Duke, I have no use for it.

Similar Messages

  • Netbeans: adding to jPanel via code after init (jFreeChart)

    This will be my second post. Many thanks to those who replied to my first questions.
    I am using netbeans 5.5
    I am attempting to run the following jFreeChart demo but in netbeans.
    Original demo located here: http://www.java2s.com/Code/Java/Chart/JFreeChartPieChartDemo7.htm
    Instead of programically creating the jPanel like the demo does, i would like to do it using the netbeans GUI and then add the code to create the jFreeChart.
    In netbeans i create a new project, create a new jFrame and place a new jPanel on the form (keeping the variable name jPanel1) as illustrated below:
    * MainForm.java
    * Created on June 28, 2007, 1:48 PM
    package mypkg;
    import org.jfree.chart.ChartFactory;
    import org.jfree.chart.ChartPanel;
    import org.jfree.chart.JFreeChart;
    import org.jfree.chart.plot.PiePlot;
    import org.jfree.chart.plot.PiePlot3D;
    import org.jfree.data.general.DefaultPieDataset;
    import org.jfree.ui.ApplicationFrame;
    import org.jfree.ui.RefineryUtilities;
    * @author  me
    public class MainForm extends javax.swing.JFrame {
        /** Creates new form MainForm */
        public MainForm() {
            initComponents();
        /** Netbeans Auto-Generated Code goes here which I have omitted */                       
         * @param args the command line arguments
        public static void main(String args[]) {
            java.awt.EventQueue.invokeLater(new Runnable() {
                public void run() {
                    new MainForm().setVisible(true);
        private void CreateChart() {
            DefaultPieDataset dataset = new DefaultPieDataset();
            dataset.setValue("Section 1", 23.3);
            dataset.setValue("Section 2", 56.5);
            dataset.setValue("Section 3", 43.3);
            dataset.setValue("Section 4", 11.1);
            JFreeChart chart3 = ChartFactory.createPieChart3D("Chart 3", dataset, false, false, false);
            PiePlot3D plot3 = (PiePlot3D) chart3.getPlot();
            plot3.setForegroundAlpha(0.6f);
            plot3.setCircular(true);
            jPanel1.add(new ChartPanel(chart3));
            jPanel1.validate();
        // Variables declaration - do not modify                    
        private javax.swing.JPanel jPanel1;
        // End of variables declaration                  
    }I then attempted to call the CreateChart() function in several places (in the MainForm() function, in the pre and post creation code properties of the jPanel's properties dialog in netbeans (as well as pre and post init in the same screen)) and nothing seems to work. the program compiles and the jFrame comes up but the chart does not show.
    If i run the example at the above noted link it runs fine in netbeans if i copy and paste the code directly, it just doesnt work when i try to get it to work through the netbeans GUI builder and the jPanel i create through it.
    Can any more advanced netbeans/java users lend me a hand or point me in the right direction?
    NOTE: in the code pasted above, i am only trying to run one of the four chart demo's listed in the original source in the link.
    NOTE2: in the code pasted above it doesnt show me calling CreateChart() from anywhere, im hoping to get some advice on how to proceed from here.
    Message was edited by:
    amadman

    Here is the netbeans generated code that i had omitted in the post above:
    private void initComponents() {
            jPanel1 = new javax.swing.JPanel();
            setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
            CreateChart(); //this is one of the many places i tried sticking the function
            javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);
            jPanel1.setLayout(jPanel1Layout);
            jPanel1Layout.setHorizontalGroup(
                jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                .addGap(0, 546, Short.MAX_VALUE)
            jPanel1Layout.setVerticalGroup(
                jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                .addGap(0, 398, Short.MAX_VALUE)
            layout.setHorizontalGroup(
                layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                .addGroup(layout.createSequentialGroup()
                    .addContainerGap()
                    .addComponent(jPanel1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addContainerGap())
            layout.setVerticalGroup(
                layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                .addGroup(layout.createSequentialGroup()
                    .addContainerGap()
                    .addComponent(jPanel1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addContainerGap())
            pack();
        }// </editor-fold>   I believe this is what you mentioned looking for, or close to it:
    javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
            getContentPane().setLayout(layout);any thoughts?

  • Problem to print a JPanel containing jfreeChart

    I need help
    I am developping an application that should display and print reports with histograms.
    I make the histogram with Jfreechart and put it on a JPanel. the report is a Vector of JPanel.
    1. When i print only the panel containing the JFreechart, the panel is printed but the range axis label
    of JFreechart is inverted.
    2. When i print all the report, nothing appears on the page of the panel containing JFreechart.
    here is my printing code:
    //code
    public int print(Graphics g, PageFormat pageFormat, int pageIndex) throws PrinterException {
    if (pageIndex >= docToBePrinted.size()) {
    return (NO_SUCH_PAGE);
    } else {
    componentToBePrinted = docToBePrinted.get(pageIndex);
    //componentToBePrinted.repaint();
    Dimension dim = componentToBePrinted.getSize();
    double scaleX = pageFormat.getImageableWidth() / dim.width;
    double scaleY = pageFormat.getImageableHeight() / dim.height;
    double scale = Math.min(scaleX, scaleY);
    Graphics2D g2D = (Graphics2D) g;
    // g2D.translate(0, 0);
    g2D.translate(pageFormat.getImageableX(), pageFormat.getImageableY());
    g2D.scale(scale, scale);
    g2D.setPaintMode();
    disableDoubleBuffering(componentToBePrinted);
    componentToBePrinted.print(g2D);
    g2D.dispose();
    //componentToBePrinted.printAll(g2D);
    enableDoubleBuffering(componentToBePrinted);
    //componentToBePrinted.
    return (PAGE_EXISTS);
    //end of code
    "docToBePrinted" is the report
    Could anyone help me please !

    I have the same problem. Similarly to another entry here, be very careful about how many times you reattempt it. I did it several times, hoping it would work out a kink, and it was on an expensive order, now there are over $2000 of "temporary authorizations" depleting my available credit on my card, and it's been that way for almost a week now.
    I am living overseas, and am unfortunately restricted to dial-up internet to upload this, and it either gets stuck at 64kb/8Mb or just jumps right to 8/8Mb, when there is nothing wrong with the my internet connection.
    I emailed Apple in response to the order cancellation email, and stated that perhaps it was the army firewall I'm behind, asking for the site the program connects to in an attempt to unblock the site if it's inadvertently getting blocked on my end. When they replied they said it's a technical issue and that I can call Apple to talk with someone, where they will determine how much the call will cost. That's outrageous to have something brand new, and have to pay for them to help you on an issue that truly may be as simple as giving out a website.
    In response to an earlier reply, I am using iPhoto 5.0.4, and I just purchased my G5 back in October. Is there a later version to iLife that I'm not finding?
    If anyone finds help with this issue, I would greatly appreciate some tips!
    Thanks so much,
    Dave

  • Exception while adding a chrtpanel(component of JFreeChart) to JTextPane.

    hi,
    Please help for solving the following exception while adding a chrtpanel(component of JFreeChart) to JTextPane
    java.lang.ArrayIndexOutOfBoundsException: No such child: 0
         at java.awt.Container.getComponent(Container.java:237)
         at javax.swing.text.ComponentView$Invalidator.cacheChildSizes(ComponentView.jav
    a:399)
         at javax.swing.text.ComponentView$Invalidator.doLayout(ComponentView.java:383)
         at java.awt.Container.validateTree(Container.java:1092)
         at java.awt.Container.validate(Container.java:1067)
         at javax.swing.text.ComponentView$Invalidator.validateIfNecessary(ComponentView
    .java:394)
         at javax.swing.text.ComponentView$Invalidator.getPreferredSize(ComponentView.ja
    va:427)
         at javax.swing.text.ComponentView.getPreferredSpan(ComponentView.java:119)
         at javax.swing.text.FlowView$LogicalView.getPreferredSpan(FlowView.java:679)
         at javax.swing.text.FlowView.calculateMinorAxisRequirements(FlowView.java:214)
         at javax.swing.text.BoxView.checkRequests(BoxView.java:913)
         at javax.swing.text.BoxView.getMinimumSpan(BoxView.java:542)
         at javax.swing.text.BoxView.calculateMinorAxisRequirements(BoxView.java:881)
         at javax.swing.text.BoxView.checkRequests(BoxView.java:913)
         at javax.swing.text.BoxView.setSpanOnAxis(BoxView.java:325)
         at javax.swing.text.BoxView.layout(BoxView.java:682)
         at javax.swing.text.BoxView.setSize(BoxView.java:379)
         at javax.swing.plaf.basic.BasicTextUI$RootView.setSize(BasicTextUI.java:1599)
         at javax.swing.plaf.basic.BasicTextUI.getPreferredSize(BasicTextUI.java:801)
         at javax.swing.JComponent.getPreferredSize(JComponent.java:1275)
         at javax.swing.JEditorPane.getPreferredSize(JEditorPane.java:1212)
         at javax.swing.ScrollPaneLayout.layoutContainer(ScrollPaneLayout.java:769)
         at java.awt.Container.layout(Container.java:1020)
         at java.awt.Container.doLayout(Container.java:1010)
         at java.awt.Container.validateTree(Container.java:1092)
         at java.awt.Container.validateTree(Container.java:1099)
         at java.awt.Container.validateTree(Container.java:1099)
         at java.awt.Container.validateTree(Container.java:1099)
         at java.awt.Container.validateTree(Container.java:1099)
         at java.awt.Container.validateTree(Container.java:1099)
         at java.awt.Container.validateTree(Container.java:1099)
         at java.awt.Container.validateTree(Container.java:1099)
         at java.awt.Container.validateTree(Container.java:1099)
         at java.awt.Container.validateTree(Container.java:1099)
         at java.awt.Container.validate(Container.java:1067)
         at javax.swing.RepaintManager.validateInvalidComponents(RepaintManager.java:353
         at javax.swing.SystemEventQueueUtilities$ComponentWorkRequest.run(SystemEventQu
    eueUtilities.java:116)
         at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:178)
         at java.awt.EventQueue.dispatchEvent(EventQueue.java:454)
         at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.ja
    va:201)
         at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java
    :151)
         at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:145)
         at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:137)
         at java.awt.EventDispatchThread.run(EventDispatchThread.java:100)

    I tried with the following link
    http://www.onjava.com/pub/a/onjava/2004/03/10/blackmamba.html?page=2
    one place this one is getting solved. Some other places atill the exeception is present.

  • ANN: SAP GUI for Java 7.10 available for download

    Hi all,
    SAP GUI for Java 7.10 is now available at <b>http://service.sap.com/sapgui-java</b>.
    In case you are not registered on service.sap.com, you can alternatively download it from ftp://ftp.sap.com/pub/sapgui/java/710.
    <b>New platforms:</b>
    - JSE 6: See System Requirements of platforms for details. Also, usage of JRE 1.4.2 is no longer supported.
    - Microsoft Windows Vista (Business and Ultimate editions)
    - Mac OS X 10.5 (once the test on the final build of "Leopard" has been successfully completed, see <a href="https://service.sap.com/sap/support/notes/959236">Note 959236</a> for latest news)
    - HP-UX 11.31
    <b>New features:</b>
    - <b>Input History: </b>Text previously entered in an entry field is available in a dropdown listbox when the same entry field is reaccessed.
    - The <b>installer</b> now can be launched directly from a write-protected directory and the installation process completes considerably faster.
    - The <b>Preference Dialog</b> has been redesigned.
    - <b>Dynpro Splitter:</b> The feature to display two subscreens divided by a horizontal or vertical splitter has been implemented.
    <a href="https://service.sap.com/sap/support/notes/959236">Note 959236</a> lists the supported platforms and will include latest news on support for Mac OS X 10.5 (Leopard).
    Best regards
    Rolf-Martin

    Hello Mac users,
    ANN: SAP GUI for Java 7.10 rev 1 available for download officially supports Leopard.
    Best regards
    Rolf-Martin

  • Setting colors for item labels in JFreeChart (WaferMapRenderer)

    Hi,
    first of all, sorry for posting a JFreeChart related posting on this forum, but I didn't get a solution right now (I even didn't find anything useful on the JFreeChart website/forum). Here's my question...
    I'm trying to set the color for item labels in the legend but with no success.
    Here's a code example:
    final JFreeChart chart = ChartFactory.createWaferMapChart(
        "Wafer Map Demo",         // title
        dataset,                  // wafermapdataset
        PlotOrientation.VERTICAL, // vertical = notchdown
        true,                     // legend          
        true,                    // tooltips
        false
    WaferMapPlot plot = (WaferMapPlot) chart.getPlot();
    WaferMapRenderer renderer = new WaferMapRenderer();
    renderer.setSeriesItemLabelPaint(0, Color.red);
    renderer.setSeriesItemLabelPaint(1, Color.blue);
    plot.setRenderer(renderer);The default behavior of the WaferMapRenderer is also strange because the item label as well as the item marker is painted black so you cannot distinguish different fields of the wafer map. Is this a bug or am I doing something wrong (or missing somehting)?
    Any help would be greatly appreciated.
    Thanks and best regards,
    - Stephan

    Your folder action script doesn't work because of one simple error:
    set label index of every item of entire contents of processFolder to 7
    Nowhere in your script is 'processFolder' defined, so AppleScript has no idea what you're trying to do.
    Given that you (correctly) iterate through added_items, the correct format would be:
    on adding folder items to this_folder after receiving added_items
      repeat with item_ in added_items
        tell application "Finder"
          set label index of item_ to 7
        end tell
      end repeat
    end adding folder items to
    In other words, this changes the label index of each item just added.
    That should work provided you're dropping files into this folder. If you're dropping folders then this would set the label index of the folder itself, but not necessarily the items within that folder. For that you'd need to add a check to see if item_ was a folder and add code to handle folders.
    Also note that this kind of folder action will only work on the folder itself - that is, if you have folder A that contains subfolder B, then dropping a file into subfolder B won't trigger the script and won't change that item's label. To do that you'd have to attach your folder action to subfolder B.

  • Hi please forword this massage  I have a problem whith paid registration  When i did check and bought 2 ringtones  i paid her  Yesterday but amount taken off my card and i do not know why   If you have  a subscrition to someting please delete ann just qhe

    Hi please forword this massage
    I have a problem whith paid registration
    When i did check and bought 2 ringtones  i paid her
    Yesterday but amount taken off my card and i do not know why 
    If you have  a subscrition to someting please delete ann just qhen i dicide to buy someting then i take maney
    Sent from my iPhone

    Please repost in your native language, as your present post makes no sense.

  • ANN vCam AS3

    Announcing vCam AS3 for Flash. For those of you who are
    unfamiliar with vCam, I’ll give you a brief explanation. In
    2005, Sham Bhangal and Dave Dixon released the original vCam or
    “virtul camera” for Flash. Let’s say you are
    working on an animation and you want the animation to pan from left
    to right. Normally you would have to create tweens for all the
    layers in your timeline. However, the vCam allows a Flash developer
    to animate a single vCam instance on the timeline to create the
    same pan. Simply place the vCam on left side of the stage and
    create a motion tween to the right side of the stage. Publish out
    your file and bam! You’ve just made your scene pan with a
    single tween. Pans aren’t the only thing you could do with
    vCam. You could also change it’s size and add color
    transformations.
    Now vCam AS3 brings a whole new list of features, including:
    - Rotation
    - Blur
    - Brightness/Contrast
    - Hue/Saturation
    - and more!
    Visit
    www.bryanheisey.com for more
    information and download the source for free.

    As this does sound nice, please refrain from advertising
    here. Read the posting guidlines
    "We gave at the office! No advertising or solicitation is
    permitted on Adobe's Online Forums. However, if you have an
    announcement to make that is of direct interest to a particular
    forum topic - a single post is acceptable, as long as you add 'ANN'
    (for 'announcement') to the beginning of your subject line. This
    way people who are not interested can easily skip past your post."
    So, maybe you could change your topic title to read "ANN vCam
    blah blah". However, it really should be in the ActionScript 3
    forums, and not under general.

  • I get this error message when I try to back up my laptop:  Time machine could not complete the backup.  The backup disc image "/Volumes/Data/Lou Ann Buesing's Mac Book Pro. sparse bundle is already in use.  Anyone know how to fix it?

    I get this error message when I try to back up my laptop:
    ' Time machine could not complete the backup.  The backup disc image "/Volumes/Data/Lou Ann Buesing's Mac Book Pro. sparse bundle' is already in use. "
    Anyone know how to fix it?

    Reboot the TC.. Sometimes you need to reboot the whole network.
    This is what comes of Lion and then made worse in Mountain Lion of Apple not spending enough time to fix the bugs.
    Read C12 in pondini.
    http://pondini.org/TM/Troubleshooting.html
    C17 can be related I think.

  • JFreeChart Line Chart points

    Hi coders, I have implemented a line chart from the JFreeChart and have got it working nearly how i want. The only problem i have now is that there are 2series using a line and 1 series using points, i was wondering if anyone knew how i could change the colour of the individual series and also the type of point or line they may have.
    public ChartPanel allAlgorithm()
                   final XYDataset alldataset = createDatasetLine();
                 final JFreeChart lineGraph1 = createChart(alldataset);
                 panel6 = new ChartPanel(lineGraph1);
                   return panel6;
              * Creates a sample dataset.
              * @return a sample dataset.
             private XYDataset createDatasetLine() {
                 XYSeries series0 = new XYSeries("Straight Comaprison");
                  XYSeries series1 = new XYSeries("Minimum Edit Distance");
                 XYSeries series2 = new XYSeries("Longest Common Sequence");
                 int users = 1;
                 resultsArray = results.getResultSet();
                   //assign the results data to the ArrayList
                   int totalFile = resultsArray.length;;
                   //a for loop to returnt he usernames from the ArrayList and also to
                   //return the data from the 2D Array
                  for (int i = 0; i < resultsArray.length; i++){
                       String x = StraComp[0];
                   String y = MinEdit[i][0];
                   String z = Lcs[i][0];
                             //System.out.println("Total File Size"+totalFile);
                             if(x.equals("XXXX")){
                                  //do nothing
                             }else{
                                  //changes the value to a double
                                  double dbX = Double.parseDouble(x);
                                  double percetX = (totalFile/dbX) * 100;
                                  if(percetX >= 100){
                                       percetX = 100;
                                  series0.add(percetX, users);
                             if(y.equals("XXXX")){
                                  //do nothing
                             }else{
                                  //changes the value to a double
                                  double dbY = Double.parseDouble(y);
                                  double percetY = (totalFile/dbY) * 100;
                                  if(percetY >= 100){
                                  percetY = 100;
                                  series1.add(percetY, users);
                             if(z.equals("XXXX")){
                                  //do nothing
                             }else{
                                  //changes the value to a double
                                  double dbZ = Double.parseDouble(z);      
                                  double percetZ = (totalFile/dbZ) * 100;
                                  if(percetZ >= 100){
                                       percetZ = 100;
                                  series2.add(percetZ, users);
                             users++;
         XYSeriesCollection alldataset = new XYSeriesCollection();
         alldataset.addSeries(series0);
         alldataset.addSeries(series1);
         alldataset.addSeries(series2);
         return alldataset;
         * Creates a chart.
         * @param dataset the data for the chart.
         * @return a chart.
         private JFreeChart createChart(final XYDataset alldataset) {
         // create the chart...
         final JFreeChart chart = ChartFactory.createXYLineChart(
         "All Algorithms Together",     // chart title
         "Number of Lines", // x axis label
         "Users", // y axis label
         alldataset,      // data
         PlotOrientation.VERTICAL,
         true, // include legend
         true, // tooltips
         false // urls
         chart.setBackgroundPaint(Color.white);
         // get a reference to the plot for further customisation...
         final XYPlot plot = chart.getXYPlot();
         plot.setBackgroundPaint(Color.lightGray);
         plot.setDomainGridlinePaint(Color.white);
         plot.setRangeGridlinePaint(Color.white);
         final XYLineAndShapeRenderer renderer = new XYLineAndShapeRenderer();
         renderer.setSeriesLinesVisible(0, false);
         renderer.setSeriesShapesVisible(1, false);
         plot.setRenderer(renderer);
         // change the auto tick unit selection to integer units only...
         final NumberAxis rangeAxis = (NumberAxis) plot.getRangeAxis();
         rangeAxis.setStandardTickUnits(NumberAxis.createIntegerTickUnits());
         return chart;

    I would try posting to the JFreeChart forum. They would probably have the best knowledge and maybe someone there may have done it before.
    http://www.jfree.org/phpBB2/index.php
    Darren

  • JFreechart and JSP, DefaultCategoryDataset is not identified

    Hi,
    Im using JFreechart in my application. Im just using a simple cahrt 2 check. If it works fine then i wil b apple to develop mi entire application. But i face the following problem. I placed al the jar files of JFreechart in root/webinf/lib/ but then DefaultCategoryDataset is not being identified. Can anyone please guide me whats the problem is?
    I hv enclosed the coding and the error with this mail.
    <%@page contentType="text/html;charset=big5"%>
    <%@page import="org.jfree.data.*"%>
    <%@page import="org.jfree.chart.*"%>
    <%@page import="java.io.*"%>
    <FORM METHOD="POST" name="chartform" action="Chart.jsp">
    <%
    DefaultCategoryDataset myDataSet=new DefaultCategoryDataset();
    myDataSet.setValue("apple",100);
    myDataSet.setValue("pear",200);
    myDataSet.setValue("grape",300);
    myDataSet.setValue("bannana",400);
    myDataSet.setValue("orange",500);
    JFreeChart chart=ChartFactory.createPieChart3D("fruit production chart",myDataSet,true,true,true);
    chart.setBackgroundPaint(java.awt.Color.white);
    chart.setBorderVisible(false);
    %>
    <img src="servlet/showChart" border=0>
    <Center><Input type="Submit" value="Generate..."/></Center>
    </FORM>
    </BODY>
    </HTML>
    -----------showChart code------------------
    import java.io.*;
    import javax.servlet.*;
    import org.jfree.data.*;
    import org.jfree.chart.*;
    import javax.servlet.http.*;
    import javax.servlet.*;
    public class showChart extends HttpServlet
    public void doGet(HttpServletRequest request, HttpServletResponse response) throws IOException, ServletException
    ChartRenderingInfo thisImageMapInfo=new ChartRenderingInfo();
    HttpSession thisSession = request.getSession();
    response.setContentType("image/jpeg");
    JFreeChart thisChart=(JFreeChart)thisSession.getAttribute("chart");
    ChartUtilities.writeChartAsJPEG(response.getOutputStream(),100,thisChart,400,300,thisImageMapInfo);
    I have placed both the files in same folder. and complied the class. Is it enuf or whats the procedure to connect JSP and its correspondibg servlet.
    ----------------error--------------------------
    org.apache.jasper.JasperException: Unable to compile class for JSP
    An error occurred at line: 15 in the jsp file: /Teresa/Chart.jsp
    Generated servlet error:
    DefaultCategoryDataset cannot be resolved or is not a type
    An error occurred at line: 15 in the jsp file: /Teresa/Chart.jsp
    Generated servlet error:
    DefaultCategoryDataset cannot be resolved or is not a type
         org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:84)
         org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:328)
         org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:397)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:288)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:267)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:255)
         org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:556)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:293)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:291)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
    any help is appreciated...thanks in advance
    Regards,
    Carry.

    sorry, I path name i hv specified is having some typo
    error
    but the jar files are in right path as said by u
    anything else to help me...yes, you havent imported the package
    <%@page import="org.jfree.data.category.*"%>Importing org.jfree.data.* doesnt import the sub-packages :)
    cheers,
    ram.

  • JFreechart objekt in JSP HELP:((

    Hello,
    I have created a JFreeChart object which represents a line chart. Now I want to display this line chart in my jsp site? could anybody explain me how I can solve this problem?
    thanks in advance
    PS: I don't want to use CeWolf.:(

    Hello,
    I have created a JFreeChart object which represents a line chart. Now I want to display this line chart in my jsp site? could anybody explain me how I can solve this problem?
    thanks in advance
    PS: I don't want to use CeWolf.:(

  • Problem in displaying text inside the item label - JFREECHART

    Hi All,
    I dont know whether this is the right place or not to post the queries related to jfreechart here .
    I am facing a problem in displaying the text inside the item label in jfreeChart. I am trying to print the text in 2 lines one below the other at the top of each bar in waterfall chart.
    Please find the code below in next post. The problem i am facing is it is neglecting the new line character . If any one knows how to display the text one below the other please help me out .
    Thanks in advance .
    Regards,
    Diw

    i am facing the problem in pasting the complete code as its exceeds the message text limitiation, please find the link below for the code .
    http://www.java-forums.org/java-2d/12087-problem-displaying-text-inside-item-label-jfreechart.html#post36648
    Early response will be appreciated . Thanks in advance
    Regards,
    Diw
    Edited by: Diw on Sep 30, 2008 11:15 AM
    Edited by: Diw on Sep 30, 2008 11:16 AM

  • Questions and Answers for Ann Rosenberg for March 11 Webinar

    Hello,
    Please reply to this thread with any questions or discussion points related to Ann Rosenberg's Webinar on March 11, 8AM PST "Running a Successful BPM Practice for SAP Customers"
    [View the announcement page|https://www.sdn.sap.com/irj/scn/wiki?path=/display/events/annRosenbergWebinar-RunningaSuccessfulBPMPracticeforSAPCustomers%252CWedsMarch11%252C11AMEastern]for more information, or to register.
    About the speaker
    Ann Rosenberg is Global Practice Head for Business Process Management in SAP's Business Transformation Consulting Team.  Ms. Rosenberg has been with SAP since 2000, holds a Black Belt in Six Sigma, and an executive MBA from SIMI. She has extensive experience in setting up BPM competency centers, and helping IT departments execute transformational change to support process-oriented organizations. Ms. Rosenberg recently published the book Business Process Management - The SAP Roadmap.

    Hi Ashish,
    There are several options for you. With the process list that is part of the Process Desk, you can display all running, completed, and canceled processes that are relevant for you.  [Displaying Processes in the Process List|http://help.sap.com/saphelp_nwce711/helpdata/en/d1/6d5ee426da4a84951c5acad77a1911/content.htm ] 
    In addition, with SAP NetWeaver Administrator, if you have administrative rights to a process you can find out if the process completed successfully or not, who executed tasks in the process, what is the data in the process context, etc.  [Managing Processes and Tasks with SAP NetWeaver Administrator|http://help.sap.com/saphelp_nwce711/helpdata/en/58/c325d5323b447ebb9d020c7fbaa5be/content.htm]
    Currently there is not a public API for accessing the native process metadata, but this will come with wave 2.  However, if you have important process metrics that you would like to track today, you can always add an automated activity to your process model that posts process data to a web service.
    Kind regards,
    Michael
    Updated links

  • Date/Time on X-Axis with JFreeChart

    Hi guys,
    I've asked this question on the JFreeChart forums, but got no response.
    If anyone has any experience with JFreeChart, help would be most appreaciated.
    I am drawing a XY Line Chart to display CPU usage retrieved from a database. The user can search with specific dates/times (eg: from: 24/2/2005 to: 16/4/2005) - and then these results would be graphed.
    My question is, how do I use dates/times on the X-axis using JFreeChart?
    The results I am getting from the DB would be a time-stamp and CPU usage.
    Here is my current code, but it wont work with a time-stamp:
    public static class ChartTest   {
        public ChartTest()
            // create a dataset...FOR LOOP
            XYSeries dataSet = new XYSeries("CPU Usage");
            TimeSeries closing = new TimeSeries( "Closing Value", Day.class );
         for(int h=0; h < newArray[0].length; h++)
            for(int i=0; i < newArray.length; i++)
               dataSet.add(newArray[i][h], newArray[i][h++]);
            XYDataset xyDataset = new XYSeriesCollection(dataSet);
            // create a chart...
            JFreeChart lineGraph = ChartFactory.createXYLineChart
                        ("Mitch's CPU Usage Test",  // Title
                          "Time",           // X-Axis label
                          "CPU Load",           // Y-Axis label
                          xyDataset,          // Dataset
                          PlotOrientation.VERTICAL,        //Plot orientation
                          true,                //show legend
                          true,                // Show tooltips
                          false               //url show
            // create and display a frame...
            ChartFrame frame = new ChartFrame("CPU Usage Test", lineGraph);
            frame.pack();
            frame.setVisible(true);
        }

    The JFreeChard demo should give you the idea
    package demo;
    import java.awt.Color;
    import java.awt.Dimension;
    import java.text.SimpleDateFormat;
    import javax.swing.JPanel;
    import org.jfree.chart.*;
    import org.jfree.chart.axis.DateAxis;
    import org.jfree.chart.plot.XYPlot;
    import org.jfree.chart.renderer.xy.XYLineAndShapeRenderer;
    import org.jfree.data.time.*;
    import org.jfree.data.xy.XYDataset;
    import org.jfree.ui.*;
    public class TimeSeriesDemo1 extends ApplicationFrame
        public TimeSeriesDemo1(String s)
            super(s);
            XYDataset xydataset = createDataset();
            JFreeChart jfreechart = createChart(xydataset);
            ChartPanel chartpanel = new ChartPanel(jfreechart, false);
            chartpanel.setPreferredSize(new Dimension(500, 270));
            chartpanel.setMouseZoomable(true, false);
            setContentPane(chartpanel);
        private static JFreeChart createChart(XYDataset xydataset)
            JFreeChart jfreechart = ChartFactory.createTimeSeriesChart("Legal & General Unit Trust Prices", "Date", "Price Per Unit", xydataset, true, true, false);
            jfreechart.setBackgroundPaint(Color.white);
            XYPlot xyplot = (XYPlot)jfreechart.getPlot();
            xyplot.setBackgroundPaint(Color.lightGray);
            xyplot.setDomainGridlinePaint(Color.white);
            xyplot.setRangeGridlinePaint(Color.white);
            xyplot.setAxisOffset(new RectangleInsets(5, 5, 5, 5));
            xyplot.setDomainCrosshairVisible(true);
            xyplot.setRangeCrosshairVisible(true);
            org.jfree.chart.renderer.xy.XYItemRenderer xyitemrenderer = xyplot.getRenderer();
            if(xyitemrenderer instanceof XYLineAndShapeRenderer)
                XYLineAndShapeRenderer xylineandshaperenderer = (XYLineAndShapeRenderer)xyitemrenderer;
                xylineandshaperenderer.setDefaultShapesVisible(true);
                xylineandshaperenderer.setDefaultShapesFilled(true);
            DateAxis dateaxis = (DateAxis)xyplot.getDomainAxis();
            dateaxis.setDateFormatOverride(new SimpleDateFormat("MMM-yyyy"));
            return jfreechart;
        private static XYDataset createDataset()
            TimeSeries timeseries = new TimeSeries("L&G European Index Trust", org.jfree.data.time.Month.class);
            timeseries.add(new Month(2, 2001), 181.8);
            timeseries.add(new Month(3, 2001), 167.3);
            timeseries.add(new Month(4, 2001), 153.8);
            timeseries.add(new Month(5, 2001), 167.6);
            timeseries.add(new Month(6, 2001), 158.8);
            timeseries.add(new Month(7, 2001), 148.3);
            timeseries.add(new Month(8, 2001), 153.9);
            timeseries.add(new Month(9, 2001), 142.7);
            timeseries.add(new Month(10, 2001), 123.2);
            timeseries.add(new Month(11, 2001), 131.8);
            timeseries.add(new Month(12, 2001), 139.6);
            timeseries.add(new Month(1, 2002), 142.9);
            timeseries.add(new Month(2, 2002), 138.7);
            timeseries.add(new Month(3, 2002), 137.3);
            timeseries.add(new Month(4, 2002), 143.9);
            timeseries.add(new Month(5, 2002), 139.8);
            timeseries.add(new Month(6, 2002), 137.0);
            timeseries.add(new Month(7, 2002), 132.8);
            TimeSeries timeseries1 = new TimeSeries("L&G UK Index Trust", org.jfree.data.time.Month.class);
            timeseries1.add(new Month(2, 2001), 129.6);
            timeseries1.add(new Month(3, 2001), 123.2);
            timeseries1.add(new Month(4, 2001), 117.2);
            timeseries1.add(new Month(5, 2001), 124.1);
            timeseries1.add(new Month(6, 2001), 122.6);
            timeseries1.add(new Month(7, 2001), 119.2);
            timeseries1.add(new Month(8, 2001), 116.5);
            timeseries1.add(new Month(9, 2001), 112.7);
            timeseries1.add(new Month(10, 2001), 101.5);
            timeseries1.add(new Month(11, 2001), 106.1);
            timeseries1.add(new Month(12, 2001), 110.3);
            timeseries1.add(new Month(1, 2002), 111.7);
            timeseries1.add(new Month(2, 2002), 111.0);
            timeseries1.add(new Month(3, 2002), 109.6);
            timeseries1.add(new Month(4, 2002), 113.2D);
            timeseries1.add(new Month(5, 2002), 111.6);
            timeseries1.add(new Month(6, 2002), 108.8);
            timeseries1.add(new Month(7, 2002), 101.6);
            TimeSeriesCollection timeseriescollection = new TimeSeriesCollection();
            timeseriescollection.addSeries(timeseries);
            timeseriescollection.addSeries(timeseries1);
            timeseriescollection.setDomainIsPointsInTime(true);
            return timeseriescollection;
        public static JPanel createDemoPanel()
            JFreeChart jfreechart = createChart(createDataset());
            return new ChartPanel(jfreechart);
        public static void main(String args[])
            TimeSeriesDemo1 timeseriesdemo1 = new TimeSeriesDemo1("Time Series Demo 1");
            timeseriesdemo1.pack();
            RefineryUtilities.centerFrameOnScreen(timeseriesdemo1);
            timeseriesdemo1.setVisible(true);
    }

Maybe you are looking for

  • Why are songs from certain iTunes playlists not syncing correctly on my iPhone 4S or iPad?

    Songs in my playlists within iTunes do not appear within the playlists on both my iPhone 4S or iPad when I sync these devices to my computer... Anyone have an idea for how to remedy this problem?

  • Restart ClassLoader

    I have coded a program using java.security.SecureClassLoader i encountered following problem : -> After Stopping A ClassLoader by making the object reference = null, and make another object, the old ClassLoader still save a Class cache and it still v

  • Making a delete commit automatically with ADF BC, Struts and ADF UIX

    I'm trying to create a delete action that commits to the database automatically using ADF Business Components, Struts and ADF UIX. I have a browse page from which the user can view all records in the table, and perform edit, create and delete actions

  • RSNAST00 program and NAST table.

    Can anybody tell what is the relation between RSNAST00 program and NAST Table ? 1). Actually, it seems RSNAST00 program first check the Object key entries in NAST table ...if it does not find the exact entry in NAST table, then RSNAST00 program creat

  • Error "User ID unknown"  - Muse Creative Cloud Crashes

    Muse on Creative Cloud Membership Crashes - Error "User ID unknown"  - Is this because I have moved Muse File out of the Documents Directory?