Bug 64992 - Error creating chart data when chart type is DOUGHNUT
Summary: Error creating chart data when chart type is DOUGHNUT
Status: RESOLVED DUPLICATE of bug 64950
Alias: None
Product: POI
Classification: Unclassified
Component: XDDF (show other bugs)
Version: 4.1.2-FINAL
Hardware: PC All
: P2 normal (vote)
Target Milestone: ---
Assignee: POI Developers List
Depends on: 64950
  Show dependency tree
Reported: 2020-12-16 09:08 UTC by fanjiajia
Modified: 2020-12-16 09:16 UTC (History)
0 users


Note You need to log in before you can comment on or make changes to this bug.
Description fanjiajia 2020-12-16 09:08:36 UTC
The following code in XDDFChart.createData: 
if (ChartTypes.PIE != type && ChartTypes.PIE3D != type) {
            categories = Collections.singletonMap(category.getId(), category);
            mapValues = Collections.singletonMap(values.getId(), values);

It will make error when ChartTypes is DOUGHNUT because axes area needed here.But if I do this,the docx file will not be opened.

The right condition is:
ChartTypes.PIE != type && ChartTypes.PIE3D != type && ChartTypes.DOUGHNUT !=null

Now I solve the problem by deleting all the axes after creating chart.
Comment 1 PJ Fanning 2020-12-16 09:16:21 UTC
Duplicate of https://bz.apache.org/bugzilla/show_bug.cgi?id=64950

*** This bug has been marked as a duplicate of bug 64950 ***