VSRonin / QtXlsxWriter

.xlsx file reader and writer for Qt5
http://qtxlsx.debao.me
209 stars 73 forks source link

Problem w/ Line Charts, MS Excel 2016 32-bit #29

Open ggodbold2 opened 6 years ago

ggodbold2 commented 6 years ago

Greetings - I'm trying to automate the creation of a chart. I can Bar Charts, Scatter, Pie charts with no problem. However, any Line chart cause and error upon loading the spreadsheet reported as "We found a problem with some content in SPREADSHEET_NAME. Do you want us to recover? YES/NO". There appears to be a mal-configuration in the underlying XML file.

This works fine --> QXlsx::Chart *bar3DChart = xlsxDoc.insertChart(65, 4, QSize(300, 300)); bar3DChart->setChartType(QXlsx::Chart::CT_Bar3D); bar3DChart->addSeries(QXlsx::CellRange("A50:C59"));

This causes some sort of corruption --> QXlsx::Chart *line3DChart = xlsxDoc.insertChart(85, 4, QSize(300, 300)); line3DChart->setChartType(QXlsx::Chart::CT_Line); line3DChart->addSeries(QXlsx::CellRange("A50:C59"));

Does anyone have any suggestions?

Thanks much!

S5642 commented 6 years ago

I have met this issue, did you find out the problem or any solutions?

ggodbold2 commented 6 years ago

No, I never did. I think it could be solved be diving into the XML output. Unfortunately, I have no time to do this.