Hi Guys,
Can you please tell me how to add total for Invoice Amount in Excel. Below are the fields for that I want the total.
SalesId InvoiceAmount
1001 100
1002 200
Below InvoiceAmount column I want to add total. can anybody please tell me how to add total here. Using
Total invoiceAmount += invoiceAmount;
I can get total but problem is how to print the total column wise and at the end of all record.
hi Parag,
To print the Total column-wise at the end of all the record … you can use the following as an example and write your requirement .
Column 1 Column 2
SalesId InvoiceAmount
1001 100
1002 200
At last in Export to Excel class write the following
row++;
worksheet.rows().item(row).style("@SYS4925");
cell = cells.item(row, 2) ;
cell.value(“Total Invoice Amount”);
cell.value(strfmt("%1", TotalInvoiceAmt));
Hope this will help you…Revert back after you get your result
Hi Lily,
Outside the while loop I have written the method and its working. Thanks for your help.
hi lilly.
How can I add two columns
Ex:
A B C
100 150 result
200 100
300 400
hi lilly.
How can I add two columns
Ex:
A B C
100 150 result
200 100
300 400