-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain.cpp
40 lines (38 loc) · 1.09 KB
/
main.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
#include <QtCore>
#include <iostream>
#include "CompoundFile.h"
#include "WorkbookStream.h"
int main(int argc, char *argv[])
{
QCoreApplication a(argc, argv);
//CompoundDoc::CompdDoc xls("c:/doc/test1.xls");
//cout << xls._sizeSector << " and " <<xls._sizeMiniSector;
#ifdef _DEBUGCOMPDOC
xls.PRINT_HEADER();
xls.PRINT_SECTOR();
xls.PRINT_FATSECTID();
xls.PRINT_FAT();
xls.PRINT_MINIFAT();
xls.PRINT_DIRENTRIES();
xls.PRINT_DATA();
#endif
/* std::cout<<"Finished!";
QString t=xls.ReadStream(QString::fromAscii("Workbook"),QString::fromAscii("/"));
QFile comoundfile(t);
comoundfile.open(QIODevice::ReadWrite);
QDataStream qs(&comoundfile);
qs.setByteOrder(xls.byteOrder());
quint16 i;
qs >> i;
if(i!=0x0809)
std::cout<< "it's not a biff8 file\n";
else
std::cout<< "it looks like a biff8 file\n";
*/
ExceLite::BIFF8Reader biff8("d:/doc/test9.xls");
ExceLite::worksheet sheet;
std::cout << biff8.GetTotalSheets() << "\n";
biff8.GetWorksheet(0,sheet);
std::cout<<"Finished!";
return a.exec();
}