From 9cd65bc3f516781dcf5076398b3628bf79c0c237 Mon Sep 17 00:00:00 2001 From: Debao Zhang Date: Thu, 23 Oct 2014 13:21:49 +0800 Subject: [PATCH] Improve the formula example --- examples/xlsx/formulas/main.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/examples/xlsx/formulas/main.cpp b/examples/xlsx/formulas/main.cpp index 1338841..c1af539 100644 --- a/examples/xlsx/formulas/main.cpp +++ b/examples/xlsx/formulas/main.cpp @@ -59,6 +59,7 @@ int main() sheet->write(row, 3, row*3); //C2:C19 } sheet->writeFormula("D2", CellFormula("B2:B19+C2:C19", "D2:D19", CellFormula::ArrayType)); + sheet->writeFormula("E2", CellFormula("=CONCATENATE(\"The total is \",D2:D19,\" units\")", "E2:E19", CellFormula::ArrayType)); //![2] //![21] @@ -70,6 +71,8 @@ int main() sheet->write(row, 3, row*3); //C2:C19 } sheet->writeFormula("D2", CellFormula("=B2+C2", "D2:D19", CellFormula::SharedType)); + sheet->writeFormula("E2", CellFormula("=CONCATENATE(\"The total is \",D2,\" units\")", "E2:E19", CellFormula::SharedType)); + //![21] //![3]