Are there any examples for using this lib???
Yes - look in the test folder. There are several files. The two main files show how use the library for C and C++ users. There is another one that shows formula use.
Greetings, great job with xlslib and libxls.. nice libraries.
I have one question for you, creating formulas in workseets:
if i doing:
expression_node_t *pExpFormula = maker.f(FUNC_SUM, maker.cell(*pCell, ws1,
CELL_RELATIVE_A1), maker.cell(*pCell2, ws1, CELL_RELATIVE_A1));
ws1->formula(5, 5, pExpFormula, true);
-> i get one formula like: =SUM(A1;A11), meaning add cells A1 and A11, working ok.
- > But how i can to get: =SUM(A1:A11), meaning add from cells A1 to A11..?
--> I didn\'t found any example about this
Hmm - I'm pretty sure I replied to this but its not on source forge. There was a bug - a set of methods were not exposed but are in latest release. do it this way:
expression_node_factory_t& maker = wb.GetFormulaFactory();
cell_t *c1 = sh->number(0, 0, 1.1);
sh->number(0, 1, 2.2);
cell_t *c2 = sh->number(0, 2, 3.3);
expression_node_t *pExpFormula = maker.f(FUNC_SUM, maker.area(*c1, *c2, CELL_RELATIVE_A1));
sh->formula(0, 3, pExpFormula, true);
Log in to post a comment.