QXlsx icon indicating copy to clipboard operation
QXlsx copied to clipboard

How to manipulate the Cell Type

Open PMime opened this issue 5 years ago • 1 comments

If you read a cell content in the Document class, a QVariant is returned. If the cell is empty in addition, the type is QMetaType::QString.

I would like to manipulate the cell, so that it knows if it is number, even if the cell is empty.

In the class Cell I discovered the method cellType(), but you can only read the type not write.

Thanks in advance!

PMime avatar Jul 17 '20 10:07 PMime

Dear @PMime

I am not sure if the following function will help you understand how to define the type.

void WorksheetPrivate::loadXmlSheetData(QXmlStreamReader &reader)

j2doll avatar Jul 18 '20 14:07 j2doll