PDA

View Full Version : import data from exel to tableview



daly001
1st January 2012, 12:10
can i import data from exel to tableview ????

Lykurg
1st January 2012, 12:58
Yes you can.

daly001
1st January 2012, 18:47
so who ???

ChrisW67
2nd January 2012, 23:21
However you want. There is no magic QImportFromArbitraryExcelSpreadsheet class in Qt. You have to code it yourself. Your options include:

Export the spreadsheet to CSV (or similar) and read that data in as a text file
Save the Excel spreadsheet in an XML format and use QDomDocument or QXmlStreamReader
Use ActiveQt to automate Excel and read the cell data of interest
Use ODBC to treat the Excel spreadsheet like a table