Demo of chart creation in Aspose.Excel for Java


One the capabilities I need to supply in our J2EE application is the ability to take the data shown in charts and tables and create an Excel file that matches what our application does as closely as possible. To determine if Aspose is capable of doing this, do you have a demo/example that shows creation of a chart in a worksheet using the API?



Hi Steve,

Now Aspose.Excel for Java doesn't support to create charts at run time. You can only create charts in your template file and use Aspose.Excel for Java to import them and update the source data.


Hi Laurence,

I see that creating and manipulating charts in Aspose.Excel for Java is in the to do list. Any idea the time frame when this would be available? Is the plan to implement the capabilities of Aspose.Excel?

Thanks, Steve


Hi Steve,

Aspose.Excel for .NET supports to create charts at run time and we will port it to Aspose.Excel for Java. It will take about 4-5 months to totally support it because of its complexity. To speed up the progress, could you create a sample file including your desired charts to show your need? We will make them first.


Hi Laurence,

This is based on your .Net documentation, the following chart types would be of the highest priority to us:

Line, Column, Area, Pie, Bar, XY Scatter

  • Line types: Line, Line with Markers, Line 3D
  • Column types: Column, Column Stacked, Column 3D Clusters, Column 3D Stacked
  • Area types: Area Stacked, Area 3D stacked
  • Pie Types: Pie, 3D Pie, Exploded Pie, 3D Exploded Pie
  • Bar types: Bar, Bar stacked, 3D Clustered, 3D Stacked
  • XY Scatter types: Scatter Chart
    (Also need adding polynomial trend lines to scatter with formula displayed Big Smile [:D])
  • Then some custom charts:
    Line with area, Line with bar

Then a lot of format control like legend placement, grid lines, titles, axis titles, axis labels

Will eventually need column 3D and being able to handle a second Y axis.

Besides the charting we will need to then be able to add drawing objects::We are looking at needing text boxes.(with and without borders) and arrows. We also would eventually need to insert images (jpg, gif)

Stick out tongue [:P] I know this is a lot but some of the things our existing product can do in it's reporting.



Hi Steve,

Which product are you using which can do all of these things? I think we can make charts and images. But we need investigate on text boxes issues.


We are going to be using a product called Nexaweb to do the UI. The product allows us to plug-in other products so we are going to use EasyCharts for our charting. With Nexaweb we can include the chart object on a page and then we can add a Nexaweb text object with a transparent background on top of it. It actually ends up being 2 different objects. It is similar to what you can do in Excel with adding a text box object onto the chart.



Since you have released charting in Aspose.Cells for Java. Do you have a demo that uses this capability?




Hi Steve,

Please download the latest version of Aspose.Cells for Java and check the source code in web demos. We will add the sample code to console demo in the next release.


Hi Laurence,

Thanks. I'll check the web demo.