This project has moved and is read-only. For the latest updates, please go here.

Write decimal values List with ClosedXML

Feb 2, 2012 at 7:53 PM

Hello, I'm developing a program that write some sql querys to excel file using ClosedXML library. I used executeEscalar() to store the values on a List of Decimal:

List<Decimal> lista4 = new List<decimal>();
using (SqlCommand command2 = new SqlCommand(query3,conn2)) { //16 - PRIMA
command2.Parameters.AddWithValue("@codigo", codigo);
var res1 = command2.ExecuteScalar();
if (res1 != DBNull.Value)

var rangeWithData = ws.Cell("E9").InsertData(lista4);

The values are stored correctly in a List as decimal values, but, when the list is inserted on the excel cells, when I open the excel file, the cells show 0 values.

Feb 2, 2012 at 7:55 PM

This has already been fixed. Pick up the latest source code...

Feb 3, 2012 at 11:18 AM

I'm already using latest dll version:

Feb 3, 2012 at 2:14 PM

Source Code, not binary. Sixth tab from the left.

Feb 6, 2012 at 8:07 AM

OK, thanks.