MiniExcel in Examples C# .Net 8
Published in
6 min readSep 3, 2024
Introduction
MiniExcel is a lightweight and efficient library for working with Excel files in .NET. In this article, we will explore how to use MiniExcel to read and process Excel files by examining a practical example. This example demonstrates how to analyze sales data across multiple files and generate reports based on the information extracted.
Prerequisites
Before diving into the code, ensure that you have the following:
- .NET installed on your machine.
- The MiniExcel library is installed in your project. You can install it via NuGet using the following command:
dotnet add package MiniExcel
Scenario Overview
In this example, we have:
- A
Products.xlsx
file containing product information, including product names and prices. - A directory (
D:\Sales
) containing multiple sales files named as sales managers. Each file contains data about product orders, including the date of…