Don't write cols tag when it donesn't exist
This commit is contained in:
@@ -369,6 +369,7 @@ void Worksheet::saveToXmlFile(QIODevice *device)
|
|||||||
// writer.writeAttribute("x14ac:dyDescent", "0.25");
|
// writer.writeAttribute("x14ac:dyDescent", "0.25");
|
||||||
writer.writeEndElement();//sheetFormatPr
|
writer.writeEndElement();//sheetFormatPr
|
||||||
|
|
||||||
|
if (!m_colsInfo.isEmpty()) {
|
||||||
writer.writeStartElement("cols");
|
writer.writeStartElement("cols");
|
||||||
foreach (XlsxColumnInfo *col_info, m_colsInfo) {
|
foreach (XlsxColumnInfo *col_info, m_colsInfo) {
|
||||||
writer.writeStartElement("col");
|
writer.writeStartElement("col");
|
||||||
@@ -384,6 +385,7 @@ void Worksheet::saveToXmlFile(QIODevice *device)
|
|||||||
writer.writeEndElement();//col
|
writer.writeEndElement();//col
|
||||||
}
|
}
|
||||||
writer.writeEndElement();//cols
|
writer.writeEndElement();//cols
|
||||||
|
}
|
||||||
|
|
||||||
writer.writeStartElement("sheetData");
|
writer.writeStartElement("sheetData");
|
||||||
if (m_dim_rowmax == INT32_MIN) {
|
if (m_dim_rowmax == INT32_MIN) {
|
||||||
|
|||||||
Reference in New Issue
Block a user