Quantcast
Channel: ClosedXML - The easy way to OpenXML
Viewing all articles
Browse latest Browse all 1877

New Post: ClosedXML Excel File

$
0
0
XLWorkbook wb = new XLWorkbook();
                
                foreach (DataTable dt in ds1.Tables)
                {
                    if (dt.Rows.Count > 0)
                        wb.Worksheets.Add(dt, dt.Rows[0]["TITLE"].ToString());
                }
Im using above code to add worksheet for each datatable in a dataset. I can't able to add the
worksheet..Tables.First().AutoFilter.Enabled = false;

where should i add the line?

Thnx for quick reply.. :)

Viewing all articles
Browse latest Browse all 1877

Trending Articles