How we can do multiple level subtotal using Aspose cells
I tried using following code but it did not worked.
CellArea ca = CellArea.CreateCellArea(“A2”, “M” + row.ToString());<span style="color:green;">//Apply subtotal, the consolidation function is Sum and it will applied to</span> <span style="color:green;">//Second column (B) in the list</span> cells.Subtotal(ca, 1, <span style="color:#2b91af;">ConsolidationFunction</span>.Sum, <span style="color:blue;">new</span> <span style="color:blue;">int</span>[] { 6, 7, 9, 11 }); ca = CellArea.CreateCellArea(<span style="color:#a31515;">"A2"</span>, worksheet.Cells.LastCell.Name); cells.Subtotal(ca, 3, <span style="color:#2b91af;">ConsolidationFunction</span>.Sum, <span style="color:blue;">new</span> <span style="color:blue;">int</span>[] { 6, 7, 9 }, <span style="color:blue;">false</span>, <span style="color:blue;">false</span>, <span style="color:blue;">true</span>); <span style="color:green;">//Set the direction of outline summary</span> worksheet.Outline.SummaryRowBelow = <span style="color:blue;">true</span>;</pre><pre style="font-family: Consolas; font-size: 13px; background: white;"><br></pre><pre style="font-family: Consolas; font-size: 13px; background: white;">First I have to do op 1 and then op 2 on same excel spreedsheet.</pre><pre style="font-family: Consolas; font-size: 13px; background: white;"><br></pre><pre style="font-family: Consolas; font-size: 13px; background: white;"> </pre><pre style="font-family: Consolas; font-size: 13px; background: white;"><br></pre><pre style="font-family: Consolas; font-size: 13px; background: white;"><br></pre><pre style="font-family: Consolas; font-size: 13px; background: white;"><br></pre><pre style="font-family: Consolas; font-size: 13px; background: white;"><br></pre></div>