Sum of column


Hi I am trying do sum of a column which has looks like the following.



I get the answer as zero. My formuala works for other columns which are just numbers.

How can i solve the above mentioned problem..

Also how do i convert a cell or a range of cells to number?



To Convert a cell to number, please try:

cell.PutValue(cell.StringValue, true);


Hi Laurence,

Thanks for the reply.

I use the importdatatable function for importing the data into excel. So i cannot use the putvalue method.



Please try this attached version with the following method:

public int ImportDataTable(DataTable dataTable, bool isFieldNameShown, int firstRow, byte firstColumn, bool insertRows, bool convertStringToNumber)


Hi Laurence,

Thanks for that!!!

We have bought a licence for aspose cells. Is this dll going to work with the license?



Hi Paresh,

Thanks for purchasing Aspose.Cells.

Yes. The dll will work with the license. And you can download v3.7.2 at . It includes some new enhancements.