Category - OpenXml
08 May 2020 08 May 2020 0 Comments  9347 Views
Here Mudassar Ahmed Khan has explained with an example, how to read Excel File (xls & xlsx) data in ASP.Net using C# and VB.Net.

When the Excel file is uploaded, the Excel File data is available in the InputStream property of the FileUpload control.

Using ClosedXml library, the Excel file data can be easily read from the InputStream property and displayed on Web Page using GridView in ASP.Net using C# and VB.Net.
01 Jun 2018 01 Jun 2018 0 Comments  24555 Views
Here Mudassar Ahmed Khan has explained with an example, how to read and import Excel file directly from Stream without saving in Folder (Directory) on Server’s Disk in ASP.Net using C# and VB.Net.

When the Excel file is uploaded, the Excel File data is available in the InputStream property of the FileUpload control.

Using ClosedXml, the Excel file data can be easily read from the InputStream property.
01 Jun 2018 01 Jun 2018 1 Comments  51492 Views
Here Mudassar Ahmed Khan has explained with an example, how to read (import) Excel file without using OLEDB or installing Microsoft Office Excel or Interop Library in C# and VB.Net.

The Excel file will be read using ClosedXml and OpenXml DLLs which does not require OLEDB and does not require Microsoft Office Excel or Interop Library software to be installed.
01 Jun 2018 01 Jun 2018 1 Comments  23448 Views
Here Mudassar Ahmed Khan has explained with an example, how to read and import Excel file using FileUpload control without saving in Folder (Directory) on Server’s Disk in ASP.Net using C# and VB.Net.
01 Jun 2018 01 Jun 2018 0 Comments  39808 Views
Here Mudassar Ahmed Khan has explained with an example, how to export DataGridView data to Excel file with formatting i.e. Colors and Styles in Windows Forms (WinForms) Applications using C# and VB.Net.

DataGridView cannot be exported directly to Excel file and hence need to generate a DataTable and export the DataTable to Excel file.

The DataTable will be exported to a formatted Excel file using ClosedXml library which is a wrapper of OpenXml.
31 May 2018 31 May 2018 0 Comments  19610 Views
Here Mudassar Ahmed Khan has explained with an example, how to read and import Excel file data to DataGridView using ClosedXml using C# and VB.Net in Windows Forms (Winforms) Application.
18 Jul 2017 18 Jul 2017 0 Comments  19712 Views
Here Mudassar Ahmed Khan has explained with an example, how to use OpenXml library in ASP.Net MVC Razor.

The data from the database is fetched using Entity Framework and then the data is exported and downloaded as Microsoft Excel file using ClosedXML Excel Library which is a wrapper for OpenXml Excel library.
15 Oct 2015 15 Oct 2015 5 Comments  97035 Views
Here Mudassar Ahmed Khan has explained with an example, how to read and import Excel file (Excel sheet) data to DataTable using OpenXml in ASP.Net with C# and VB.Net.
15 Oct 2015 15 Oct 2015 1 Comments  45645 Views
Here Mudassar Ahmed Khan has explained how to read and import Excel file (Excel sheet) data to GridView without using OELDB in ASP.Net using C# and VB.Net.
Since OLEDB is not used, the Excel file (Excel sheet) data will be read and imported to GridView using OpenXml library in ASP.Net using C# and VB.Net.
15 Oct 2015 15 Oct 2015 8 Comments  40931 Views
Here Mudassar Ahmed Khan has explained how to solve the following compilation error:
CS0012: The type 'System.IO.Packaging.Package' is defined in an assembly that is not referenced. You must add a reference to assembly 'WindowsBase, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35'.
The above error occurs when we use the OpenXml Packaging Library.