: Mēs pārbaudījām 12 C# Excel bibliotēkas pret identiskiem uzdevumiem: darba grāmatu izveide, lielu datu kopu lasīšana, šūnu formatēšana un eksportu starp platformām.Šī rokasgrāmata aptver visu, sākot no MIT licencētajām atvērtā koda iespējām līdz uzņēmuma līmeņa komerciāliem kompleksiem, kopā ar kodu, veiktspējas kritērijiem, licencēšanas izmaksām un lēmumu pieņemšanas sistēmu, lai palīdzētu jums izvēlēties pareizo bibliotēku savam projektam. TL;DR Šajā salīdzinājumā mēs pavadījām trīs nedēļas, strādājot katrā no 12 bibliotēkām, izmantojot identiskus testēšanas scenārijus: veidojot darba grāmatas no nulles, lasot 100 000 rindu datu kopas, piemērojot nosacītu formatēšanu un eksportējot uz XLSX un CSV gan Windows, gan Linux. Pilna izpaušana: mēs esam DevRel komanda aiz , viena no 12 bibliotēkām šajā salīdzinājumā.Tā teica, mēs uzskatām, ka godīgi vērtējumi kalpo ikvienam labāk nekā mārketinga spin.Mēs parādīsim mūsu metodoloģiju, atzīsim mūsu aizspriedumus un ļaujiet kritērijiem runāt par sevi.Ja konkurents patiesi pārspēj IronXL konkrētā lietojuma gadījumā, mēs to sakām. Ironisks Lūk, kā ainava izskatās vienā mirklī - tad mēs ejam dziļi katrā bibliotēkā. // The task every library in this article performs: // Create a workbook → write headers + 3 data rows → save as XLSX // IronXL (3 lines of core logic) using IronXL; WorkBook wb = WorkBook.Create(ExcelFileFormat.XLSX); WorkSheet ws = wb.CreateWorkSheet("Sales"); ws["A1"].Value = "Product"; ws["B1"].Value = "Revenue"; ws["A2"].Value = "Widget"; ws["B2"].DoubleValue = 14999.99; wb.SaveAs("sales_ironxl.xlsx"); IronXL izlaide Mēs parādīsim katru bibliotēkas versiju par šo uzdevumu zemāk, jo labākais veids, kā novērtēt API, ir lasīt kodu. Pirms mēs nonākam pie atsevišķiem profiliem, piezīme par metodoloģiju. Mēs novērtējām katru bibliotēku septiņās dimensijās: (cik daudz līniju, lai izpildītu kopīgus uzdevumus), (kādus failu veidus jūs varat lasīt un rakstīt), (Grāmatas, pīlāri un formulas) (Rakstīt ātrumu un atmiņas izmantošanu mērogā), (Linux, Docker un mākoņi) (patiesās izmaksas, ieskaitot slēptās izmaksas) un (izlaišanas kadence, kopienas izmērs, dokumentācijas kvalitāte). neviena bibliotēka nepārsniedz visus septiņus, katrai dimensijai piešķirtais svars nosaka jūsu labāko izvēli. API ergonomics format support feature depth performance cross-platform support licensing clarity maintenance health Kuru C# Excel bibliotēku jums vajadzētu izvēlēties? ātras atsauces tabula Pirms ienirt 12 atsevišķos profilos, šeit ir salīdzinājuma tabula. Katrs šajā tabulā minētais apgalvojums tiek pārbaudīts pret katras bibliotēkas dokumentāciju un NuGet paketi no 2026. gada februāra. Library License Entry Price XLSX Files XLS Files CSV Files .NET 8 LTS .NET 10 Linux/Docker Charts Pivot Tables Formula Engine NuGet Downloads IronXL Commercial $749/yr ✅ ✅ ✅ ✅ ✅ ✅ ❌ ❌ ✅ 3M+ EPPlus Commercial $299/yr ✅ ❌ ✅ ✅ ✅ ✅ ✅ ✅ ✅ 80M+ ClosedXML MIT Free ✅ ❌ ✅ ✅ ✅ ✅ ❌ ✅ ✅ 60M+ NPOI Apache 2.0 Free ✅ ✅ ❌ ✅ ✅ ✅ ✅ ❌ ✅ 50M+ Aspose.Cells Commercial $1,199/yr ✅ ✅ ✅ ✅ ✅ ✅ ✅ ✅ ✅ 20M+ Syncfusion XlsIO Commercial/Free* $0–$995/yr ✅ ✅ ✅ ✅ ✅ ✅ ✅ ✅ ✅ 15M+ GemBox.Spreadsheet Freemium $0–$890 ✅ ✅ ✅ ✅ ✅ ✅ ✅ ✅ ✅ 5M+ OpenXML SDK MIT Free ✅ ❌ ❌ ✅ ✅ ✅ ✅ ✅ ❌ 100M+ ExcelDataReader MIT Free ✅ ✅ ✅ ✅ ✅ ✅ ❌ ❌ ❌ 70M+ Spire.XLS Commercial $999/dev ✅ ✅ ✅ ✅ ✅ ✅ ✅ ✅ ✅ 3M+ SpreadsheetLight MIT Free ✅ ❌ ✅ ⚠️ ❌ ⚠️ ✅ ❌ ✅ 2M+ SpreadsheetGear Commercial $975/dev ✅ ✅ ✅ ✅ ✅ ✅ ✅ ❌ ✅ 1M+ IronXL Komerciālā 749 € / mēnesis ✅ ✅ ✅ ✅ ✅ ✅ ❌ ❌ ✅ 3 m + EPPlus Epipēds Komerciālā $ 299 / mēnesis ✅ ❌ ✅ ✅ ✅ ✅ ✅ ✅ ✅ 80 m+ ClosedXML SlēgtXML ar Bezmaksas ✅ ❌ ✅ ✅ ✅ ✅ ❌ ✅ ✅ 60 m+ NPOI Apache 2.0 lietošana Bezmaksas ✅ ✅ ❌ ✅ ✅ ✅ ✅ ❌ ✅ 50 m + Aspose.Cells Komerciālā $ 1,199 / mēnesis ✅ ✅ ✅ ✅ ✅ ✅ ✅ ✅ ✅ 20 m+ Syncfusion XlsIO Komerciāli / Bezmaksas * $0–$995/yr ✅ ✅ ✅ ✅ ✅ ✅ ✅ ✅ ✅ 15M+ GemBox.Spreadsheet GemBox.Spreadsheet Freemium $0–$890 ✅ ✅ ✅ ✅ ✅ ✅ ✅ ✅ ✅ 5M+ OpenXML SDK MIT Bezmaksas ✅ ❌ ❌ ✅ ✅ ✅ ✅ ✅ ❌ 100 m+ ExcelDataReader ar Bezmaksas ✅ ✅ ✅ ✅ ✅ ✅ ❌ ❌ ❌ 70 m+ Spire.XLS Spire.XLS Commercial 999 ASV dolāri/dev ✅ ✅ ✅ ✅ ✅ ✅ ✅ ✅ ✅ 3M+ SpreadsheetLight MIT Free ✅ ❌ ✅ ⚠️ ❌ ⚠️ ✅ ❌ ✅ 2 m + SpreadsheetGear Commercial 975 ASV dolāri/dev ✅ ✅ ✅ ✅ ✅ ✅ ✅ ❌ ✅ 1 m + Syncfusion piedāvā bezmaksas kopienas licenci uzņēmumiem ar ieņēmumiem < 1M $ un ≤ 5 izstrādātājiem. ⚠️ = Partial or unverified support. free Community License The short version, by scenario: → ClosedXML (MIT, mature, active development) Tight budget, full read/write? → IronXL or Aspose.Cells Enterprise-grade with premium support? Maksimālais funkciju segums? → Aspose.Cells vai Syncfusion XlsIO → ExcelDataReader Read-only, maximum speed? Zema līmeņa kontrole, bez abstrakcijas? → OpenXML SDK Java ports, legacy XLS nepieciešams? → NPOI Tagad apskatīsim katru bibliotēku sīkāk. The 12 C# Excel Libraries Worth Knowing in 2026 Katrs profils zemāk seko tai pašai struktūrai: kas ir bibliotēka, koda piemērs, kas veic standarta uzdevumu (izveidot darba grāmatu, rakstīt datus, saglabāt), tās reālie stiprās puses un ierobežojumi, un kam to vajadzētu izmantot. 1. IronXL — The All-in-One Commercial .NET Library IronXL ir komerciāla .NET Excel bibliotēka no kas prioritizē API vienkāršību un starpplatformu izvietošanu. Tas lasa un raksta XLS, XLSX, CSV, TSV un JSON, neprasot Microsoft Office. Tā plašais funkciju kopums ietver arī Microsoft Excel darbgaldu izveidi un rediģēšanu, iespēju eksportēt Excel darbgrāmatas, strādāt ar formulām un daudz ko citu. Jūs pat varat pievienot attēlu formātus savām Excel darbgaldiem. Mēneša izlaišanas biežums — jaunākā versija (2026.2) ir aprīkota ar .NET 10 atbalstu. Iron Software using IronXL; // Create a new workbook and write data WorkBook wb = WorkBook.Create(ExcelFileFormat.XLSX); WorkSheet ws = wb.CreateWorkSheet("Sales"); ws["A1"].Value = "Product"; ws["B1"].Value = "Revenue"; ws["C1"].Value = "Date"; ws["A2"].Value = "Widget"; ws["B2"].DoubleValue = 14999.99; ws["C2"].Value = DateTime.Now.ToShortDateString(); // Apply formatting ws["B1:B2"].FormatString = "$#,##0.00"; wb.SaveAs("sales_ironxl.xlsx"); IronXL Output Excel File API izmanto WorkBook → WorkSheet → šūnu adresēšanas modeli, kas atspoguļo to, kā izstrādātāji domā par tabulām. Šūnu adresēšana atbalsta gan A1 notāciju (ws["B2"]), gan diapazona izteiksmes (ws["A1:C10"]), un FormatString īpašums pieņem standarta Excel formāta kodus. Bibliotēka automātiski apstrādā formulas pārrēķinu, kad šūnas tiek rediģētas. Strengths: Minimal boilerplate, create, read, and export data in 3-5 lines of code. This makes is a piece of cake to add into your .NET applications Cross-platform: Windows, Linux, macOS, Docker, Azure, AWS Lambda — visi ir pārbaudīti. Monthly releases with active bug fixes; the API-level simplicity is the primary differentiator, not raw throughput (see Benchmarks section for honest numbers) Supports XLS (legacy) + XLSX + CSV + TSV + JSON in a unified API Real-world deployment: uses IronXL for nonprofit financial reconciliation, achieving 4× faster payment processing; powers logistics and healthcare Excel automation across Germany Brainycom ThreeB IT Limitations: Nav diagrammu izveides (jūs varat izlasīt esošos diagrammas, bet tos nevar ģenerēt programmatiski) Nav pivot tabulas paaudzes Commercial license required for production ($749/year for Lite) Smaller community compared to EPPlus or ClosedXML Teams that need a clean API for reading/writing/exporting Excel data across platforms, don't need chart generation, and value professional support and frequent updates. Strong fit for data pipelines, report generation, and CSV/Excel conversion workflows. Best for: 2. Kopienas mīļākie gāja komerciāli EPPlus EPPlus ir viena no visvairāk lejupielādētajām .NET Excel bibliotēkām vēsturē. Pēdējā brīva versija ( ) remains widely used but unmaintained. The commercial version is feature-rich with charts, pivot tables, and a strong formula engine. Pāreja uz komerciālu Polyform licenci 5.3 Nūjošana using OfficeOpenXml; ExcelPackage.License.SetNonCommercialOrganization("My Organization"); using var package = new ExcelPackage(); var ws = package.Workbook.Worksheets.Add("Sales"); ws.Cells["A1"].Value = "Product"; ws.Cells["B1"].Value = "Revenue"; ws.Cells["C1"].Value = "Date"; ws.Cells["A2"].Value = "Widget"; ws.Cells["B2"].Value = 14999.99; ws.Cells["C2"].Value = DateTime.Now; ws.Cells["C2"].Style.Numberformat.Format = "yyyy-mm-dd"; ws.Cells["B1:B2"].Style.Numberformat.Format = "$#,##0.00"; package.SaveAs(new FileInfo("sales_epplus.xlsx")); EEPlus iznākums EPPlus izmanto ExcelPackage → Workbook → Worksheets hierarhiju, kas cieši atspoguļo Excel objekta modeli. Šūnu īpašums pieņem A1 stila atsauces, un stilēšana tiek piemērota, izmantojot nested Style objektu. Ņemiet vērā licences konfigurācijas līniju, EPPlus 5+ prasa iestatīt licences kontekstu pirms jebkuras darbības. Strengths: Massive community and ecosystem, 80M+ NuGet downloads, extensive Stack Overflow coverage Charts, pivot tables, conditional formatting, data validation, VBA support Powerful LoadFromCollection<T>() and LoadFromDataTable() for object-to-Excel mapping Pieaugušo formulas dzinējs ar plašu funkciju segumu Limitations: Tikai XLSX, bez XLS veco formātu atbalsta Commercial license required for any commercial use since v5 ($299/year base) Version 4.5.3 (last free version) is unmaintained and missing years of bug fixes Can struggle with memory on very large files (100K+ rows) in some configurations Komandām ar esošajiem EPPlus ieguldījumiem, projektiem, kuriem nepieciešamas diagrammas / pivot tabulas ar mērenu budžetu, un izstrādātājiem, kuri novērtē milzīgo kopienas zināšanu bāzi. Best for: ClosedXML — Atvērtā koda izstrādātāja izvēle Excel API wraps Microsoft's in a developer-friendly API. MIT-licensed, actively maintained (frequent commits on Tas ir ieteikums, kad izstrādātāji lūdz bezmaksas, pilnu funkciju Excel bibliotēku and .NET community forums. SlēgtXML OpenXML SDK GitHub Stack pārplūdes using ClosedXML.Excel; using var wb = new XLWorkbook(); var ws = wb.AddWorksheet("Sales"); ws.Cell("A1").Value = "Product"; ws.Cell("B1").Value = "Revenue"; ws.Cell("C1").Value = "Date"; ws.Cell("A2").Value = "Widget"; ws.Cell("B2").Value = 14999.99; ws.Cell("C2").Value = DateTime.Now; ws.Cell("B2").Style.NumberFormat.Format = "$#,##0.00"; wb.SaveAs("sales_closedxml.xlsx"); ClosedXML Output ClosedXML's API is intuitive: XLWorkbook → AddWorksheet → Cell() with string-based addressing. The Style property chain is clean and discoverable via IntelliSense. It builds on top of OpenXML SDK, so it generates spec-compliant .xlsx files. Strengths: MIT license, genuinely free for all use, including commercial Clean, intuitive API that makes OpenXML SDK bearable Active development with regular releases and responsive maintainers Good pivot table support and conditional formatting Large community: 60M+ NuGet downloads Limitations: Tikai XLSX, bez XLS veco formātu atbalsta No chart creation (a frequently requested feature, still unimplemented) Performance degrades with very large datasets (100K+ rows can be slow or memory-intensive) No commercial support, community-only via GitHub Issues Atvērtā koda projekti, budžeta ierobežotas komandas un jebkurš scenārijs, kurā MIT licencēšana ir nepieciešama. Best for: 4. NPOI — The Java Port That Refuses to Die is the .NET port of , the Java Excel library. It's one of the few free libraries that supports both XLS (BIFF) and XLSX (OOXML) formats. Apache 2.0 licensed. The API reflects its Java heritage, it's more verbose than C#-native alternatives, but it's battle-tested and handles legacy formats that newer libraries can't touch. Nākamais Apache pēc using NPOI.XSSF.UserModel; using NPOI.SS.UserModel; IWorkbook wb = new XSSFWorkbook(); ISheet ws = wb.CreateSheet("Sales"); IRow headerRow = ws.CreateRow(0); headerRow.CreateCell(0).SetCellValue("Product"); headerRow.CreateCell(1).SetCellValue("Revenue"); headerRow.CreateCell(2).SetCellValue("Date"); IRow dataRow = ws.CreateRow(1); dataRow.CreateCell(0).SetCellValue("Widget"); dataRow.CreateCell(1).SetCellValue(14999.99); dataRow.CreateCell(2).SetCellValue(DateTime.Now.ToShortDateString()); using var fs = new FileStream("sales_npoi.xlsx", FileMode.Create); wb.Write(fs); NPOI Output NPOI requires explicit row and cell creation via CreateRow() and CreateCell(), there's no string-based cell addressing. For XLS files, swap XSSFWorkbook with HSSFWorkbook. The interface-driven design (IWorkbook, ISheet, IRow) means the same code logic can target either format by changing a single constructor. Strengths: Apache 2.0 licence, bezmaksas komerciālai lietošanai Supports both XLS (97-2003) and XLSX, one of few free libraries that handles legacy XLS Grafiku veidošanas atbalsts (pamatinformācija) Darbojas ar Word (.doc/.docx) un PowerPoint papildus Excel dokumentiem Pierādīts uzņēmuma mērogā – portēts no Apache POI ar gadu desmitiem Java mantojuma Limitations: Verbose, Java-style API, significantly more boilerplate than C#-native alternatives Performance is generally slower than EPPlus, ClosedXML, or IronXL for equivalent operations Documentation is sparse and often in Chinese — English resources are community-contributed API var būt neintuitīvs izstrādātājiem, kas nav pazīstami ar Apache POI Projekti, kas lasīt vai rakstīt vecos XLS failus bez komerciālas licences.Tāpat piemērots, ja jums ir nepieciešama viena bibliotēka Excel + Word + PowerPoint ar nulles budžetu. Best for: must Aspose.Cells — uzņēmuma smagā svara ir visfunkcionālākā .NET Excel bibliotēka, kas pieejama. tā atbalsta gandrīz visas Excel funkcijas: diagrammas, pivot tabulas, nosacītu formatēšanu, datu validāciju, sparklīnus, šķēles, VBA makro un daudz ko citu. tā ir arī visdārgākā iespēja. Aspose to pozicionē kā pilnīgu Excel automatizācijas platformu, nevis tikai failu I/O bibliotēku. Tīkls. šūnas using Aspose.Cells; Workbook wb = new Workbook(); Worksheet ws = wb.Worksheets[0]; ws.Cells["A1"].PutValue("Product"); ws.Cells["B1"].PutValue("Revenue"); ws.Cells["C1"].PutValue("Date"); ws.Cells["A2"].PutValue("Widget"); ws.Cells["B2"].PutValue(14999.99); ws.Cells["C2"].PutValue(DateTime.Now); Style style = wb.CreateStyle(); style.Number = 7; // $#,##0.00 ws.Cells["B2"].SetStyle(style); wb.Save("sales_aspose.xlsx"); Aspose.Cells Output Aspose.Cells uses a Workbook → Worksheets → Cells hierarchy. Data is written with PutValue() rather than direct assignment. Styling requires creating a Style object and applying it, more steps than some competitors, but it provides granular control over every formatting property. Strengths: Visaptverošākā funkcija, kas iestatīta .NET Excel ekosistēmā, ja Excel to var izdarīt, Aspose.Cells, iespējams, to atbalsta Lieliskas veiktspējas lieliem failiem, kas optimizēti uzņēmuma mēroga partiju apstrādei Plašs formātu atbalsts: XLSX, XLS, XLSB, XLSM, CSV, ODS, PDF, HTML, attēli Excel-to-PDF rendering that's among the most faithful available Strong documentation, extensive code samples, and dedicated support team Limitations: Highest price point: Developer Small Business starts at $1,199/year; OEM tiers reach $11,198 API is verbose in places, creating and applying styles is more ceremonial than IronXL or ClosedXML Masveida API virsma var būt pārsteidzoša vienkāršiem uzdevumiem Smaga atkarība, NuGet pakete ir liela Uzņēmējdarbības komandas ar budžetu augstas kvalitātes rīku izstrādei, projektiem, kuriem nepieciešamas uzlabotas funkcijas (diagrammas, pīlāri, sparklīni, VBA) un darba plūsmas, kurām nepieciešama augsta ticamība . Best for: Excel-to-PDF conversion 6. Syncfusion XlsIO — The Suite Play is part of Syncfusion's massive Essential Studio suite. It offers broad Excel feature coverage and benefits from Syncfusion's cross-platform UI control ecosystem. The free Community License (for companies under $1M revenue, ≤5 developers) makes it accessible to small teams. Syncfusion Essential XlsIO priekšrocības using Syncfusion.XlsIO; using ExcelEngine excelEngine = new ExcelEngine(); IApplication app = excelEngine.Excel; app.DefaultVersion = ExcelVersion.Xlsx; IWorkbook wb = app.Workbooks.Create(1); IWorksheet ws = wb.Worksheets[0]; ws.Range["A1"].Text = "Product"; ws.Range["B1"].Text = "Revenue"; ws.Range["C1"].Text = "Date"; ws.Range["A2"].Text = "Widget"; ws.Range["B2"].Number = 14999.99; ws.Range["C2"].DateTime = DateTime.Now; ws.Range["B2"].NumberFormat = "$#,##0.00"; wb.SaveAs("sales_syncfusion.xlsx"); Syncfusion XlsIO Output Syncfusion izmanto ExcelEngine → IApplication → IWorkbook hierarhiju, kas atspoguļo Excel COM objekta modeli. Šūnu piekļuve ir caur diapazonu[] ar atsevišķām tipēšanas īpašībām (Text, Number, DateTime). Strengths: Funkciju bagātība: Izmantojiet datu avotus, lai izveidotu diagrammas, pivot tabulas, nosacītu formatēšanu, datu validāciju, veidnes marķierus, sparklīnus Free Community License for small companies, a genuine differentiator Excel-to-PDF konvertēšana ir iekļauta Deep integration with Syncfusion's Blazor, MAUI, and WPF UI controls Active development with quarterly releases; cross-platform (Windows, Linux, macOS, Docker) Limitations: Kopienas licencē ir stingras atbilstības prasības, uzņēmumiem, kuru ieņēmumi pārsniedz $ 1M, ir jāiegādājas Pilna Suite cenu noteikšana ir sarežģīta un var būt dārga ($ 995 /dev /gadā Essential Studio) Bibliotēka ir daļa no masveida komplekta, jūs velkat vairāk atkarību, nekā nepieciešams tikai Excel darbam Vendor lock-in concern: deep Syncfusion ecosystem integration can make migration difficult Teams already using Syncfusion's UI controls, startups qualifying for the free Community License, and projects needing tight integration between Excel processing and Blazor/MAUI front ends. Best for: 7. — The Performance-Focused Mid-Tier Lāčplēsis.Spreadsheet ir komerciāli licencēts .NET komponents ar iespaidīgu bezmaksas līmeni (150 rindas, 5 lapas). Tas reklamē spēcīgus veiktspējas rādītājus - uzņēmums apgalvo, ka 1 miljons rindas mazāk nekā 3,5 sekundēs ar mazāk nekā 256 MB RAM - un atbalsta neparasti plašu izejas formātu klāstu, tostarp PDF, XPS un attēlu rādīšanu. . GemBox.Spreadsheet Ūdens using GemBox.Spreadsheet; SpreadsheetInfo.SetLicense("FREE-LIMITED-KEY"); var wb = new ExcelFile(); var ws = wb.Worksheets.Add("Sales"); ws.Cells["A1"].Value = "Product"; ws.Cells["B1"].Value = "Revenue"; ws.Cells["C1"].Value = "Date"; ws.Cells["A2"].Value = "Widget"; ws.Cells["B2"].Value = 14999.99; ws.Cells["C2"].Value = DateTime.Now; ws.Cells["B2"].Style.NumberFormat = "$#,##0.00"; wb.Save("sales_gembox.xlsx"); GemBox.Spreadsheet iznākums GemBox uses ExcelFile → Worksheets → Cells with string-based addressing. The API is clean and similar to ClosedXML's pattern. The free tier key (FREE-LIMITED-KEY) enables evaluation without watermarks — just with row limits. Strengths: Strong claimed performance on large datasets (1M rows, <256MB, <3.5s) PDF, XPS, and image export built in — no separate library needed Diagrammas, pivot tabulas, nosacījuma formatēšana un datu validācijas atbalsts Free tier for small datasets (useful for prototyping) Clean, idiomatic C# API Limitations: Bezmaksas slānis ierobežots līdz 150 rindām un 5 loksnēm - pārāk ierobežojošs lielākajai daļai reālu lietojumprogrammu Smaller community than EPPlus, ClosedXML, or NPOI — fewer Stack Overflow answers Profesionālā licence sākas ~ $ 890 (vienreizējs) - konkurētspējīgs, bet ne lēts Less name recognition — harder to get team buy-in compared to established alternatives Izpildiet lielus failus apstrādājamās lietojumprogrammas, projektus, kuriem nepieciešama iebūvēta PDF/attēlu eksportēšana no Excel, un komandas, kas vērtē vienreizēju licencēšanu salīdzinājumā ar abonēšanu. Best for: 8. OpenXML SDK — The Foundation Layer nodrošina zema līmeņa piekļuvi Tas ir tas, uz kā ClosedXML un daudzas citas bibliotēkas ir veidotas. MIT licencēts, ko uztur Microsoft, un dod jums tiešu kontroli pār XML struktūru .xlsx failus. kompromiss: jūs būtībā rakstāt XML ar palīgiem. Microsoft's Open XML SDK Office Open XML documents using DocumentFormat.OpenXml; using DocumentFormat.OpenXml.Packaging; using DocumentFormat.OpenXml.Spreadsheet; using var doc = SpreadsheetDocument.Create("sales_openxml.xlsx", SpreadsheetDocumentType.Workbook); var workbookPart = doc.AddWorkbookPart(); workbookPart.Workbook = new Workbook(); var worksheetPart = workbookPart.AddNewPart<WorksheetPart>(); worksheetPart.Worksheet = new Worksheet(new SheetData()); var sheets = workbookPart.Workbook.AppendChild(new Sheets()); sheets.Append(new Sheet { Id = workbookPart.GetIdOfPart(worksheetPart), SheetId = 1, Name = "Sales" }); var sheetData = worksheetPart.Worksheet.GetFirstChild<SheetData>(); var row = new Row { RowIndex = 1 }; row.Append(new Cell { CellReference = "A1", DataType = CellValues.String, CellValue = new CellValue("Product") }); row.Append(new Cell { CellReference = "B1", DataType = CellValues.String, CellValue = new CellValue("Revenue") }); sheetData.Append(row); workbookPart.Workbook.Save(); OpenXML izeja Let's be direct: that's a lot of code just to write two cells. OpenXML SDK requires you to manually construct the XML document structure, workbook parts, worksheet parts, sheet data, rows, cells, cell references, data types. There's no worksheet["A1"] = value convenience. Strengths: MIT licencēts, ko uztur Microsoft, kā "oficiāls", kā tas kļūst Maksimāla kontrole pār dokumentu struktūru, nekas nav abstrakts Memory-efficient for streaming writes (SAX-style approach available) 100M+ NuGet lejupielādes, pamata slānis daudzas citas bibliotēkas ir atkarīgas no No third-party risk, it's from Microsoft themselves Limitations: Extremely verbose, simple tasks require 5-10× more code than any higher-level library No formula calculation engine, formulas are stored as strings, not evaluated Nav XLS atbalsta, tikai OOXML (.xlsx) No convenient cell addressing, formatting shortcuts, or data binding helpers Steep learning curve, you need to understand the OOXML specification Bibliotēku autori veido savu Excel abstrakciju, scenārijus, kas prasa absolūtu kontroli pār dokumentu struktūru, un komandas ar stingrām "neatkarību no trešajām pusēm" politikām, kas var absorbēt izstrādes izmaksas. Best for: ExcelDataReader – vieglās lasīšanas tikai speciālists does one thing and does it well: reading Excel files. It supports XLS, XLSX, and CSV through a streaming IDataReader interface that's memory-efficient for large files. MIT-licensed. If you only need to spreadsheets, this should be your first consideration. ExcelDataReader Lasīt using ExcelDataReader; using System.Data; // Required for .NET Core System.Text.Encoding.RegisterProvider(System.Text.CodePagesEncodingProvider.Instance); using var stream = File.Open("sales_data.xlsx", FileMode.Open, FileAccess.Read); using var reader = ExcelReaderFactory.CreateReader(stream); DataSet result = reader.AsDataSet(new ExcelDataSetConfiguration { ConfigureDataTable = _ => new ExcelDataTableConfiguration { UseHeaderRow = true } }); DataTable table = result.Tables[0]; foreach (DataRow row in table.Rows) { Console.WriteLine($"{row["Product"]}: {row["Revenue"]}"); } ExcelDataReader Reading Output ExcelDataReader atgriež datus, izmantojot pazīstamās System.Data saskarnes: IDataReader straumēšanai un DataSet/DataTable materializētiem rezultātiem. UseHeaderRow = patiesa konfigurācija veicina pirmo rindu kolonnas nosaukumos. Ņemiet vērā kodēšanas pakalpojumu sniedzēja reģistrāciju, kas nepieciešama .NET Core XLS formāta atbalstam. Strengths: MIT license — free for everything Lightweight: small NuGet package, minimal dependencies Streaming reader — memory-efficient for large files Atbalsta gan XLS, gan XLSX plus CSV DataTable integration makes it easy to pipe data into databases or other systems 70M+ NuGet downloads — proven reliability Limitations: — cannot create or modify Excel files Read-only No formatting, styling, charts, or formula evaluation No cell addressing — data access is row/column based only Nepieciešama manuāla kodēšanas pakalpojumu sniedzēja reģistrācija .NET Core ETL cauruļvadi, datu importēšanas darba plūsmas, migrācijas rīki un jebkurš scenārijs, kurā nepieciešams Excel data quickly and cheaply without ever writing back to a spreadsheet. Best for: Lasīt 10. EIceBlue pretinieks Spire.XLS by eIceBlue is a commercial Excel component with a free version limited to 200 rows and 5 sheets. The commercial version supports the full range of Excel features including charts, pivot tables, and Excel-to-PDF conversion. eIceBlue also offers Word, PDF, and PowerPoint libraries in their Spire.Office bundle. Spire.XLS for .NET using Spire.Xls; Workbook wb = new Workbook(); Worksheet ws = wb.Worksheets[0]; ws.Name = "Sales"; ws.Range["A1"].Text = "Product"; ws.Range["B1"].Text = "Revenue"; ws.Range["C1"].Text = "Date"; ws.Range["A2"].Text = "Widget"; ws.Range["B2"].NumberValue = 14999.99; ws.Range["C2"].DateTimeValue = DateTime.Now; ws.Range["B2"].NumberFormat = "$#,##0.00"; wb.SaveToFile("sales_spire.xlsx", ExcelVersion.Version2016); Spire.XLS iznākums Spire.XLS darbojas pēc modeļa, kas ir līdzīgs Syncfusion, Darba grāmata → Darba lapa → diapazons ar ierakstītām vērtību īpašībām. Strengths: Visaptverošs funkciju kopums: diagrammas, pīlāri, nosacīts formatējums, šifrēšana, digitālie paraksti Excel-to-PDF and Excel-to-image conversion built in Bezmaksas versija pieejama (200 rindas, 5 loksnes), dāsnāka nekā GemBox bezmaksas līmenis rindas skaitīšanai Supports XLS and XLSX Daļa no plašākas Spire.Office paketes Limitations: Bezmaksas versijas 200 sērijas ierobežojums ir pārāk ierobežojošs lielākajai daļai ražošanas izmantošanas Commercial pricing starts at ~$999/developer, on the higher end Mazāka .NET kopienas klātbūtne salīdzinājumā ar Aspose vai Syncfusion Documentation quality is inconsistent, some API areas are poorly documented Java heritage shows in some API patterns Teams evaluating commercial alternatives to Aspose.Cells at a different price point, and projects already using other Spire.Office components. Best for: 11. SpreadsheetLight — The Minimalist is an MIT-licensed library built on OpenXML SDK. It aims to be the "simple" option — easy to learn, lightweight, and sufficient for common spreadsheet tasks. The tradeoff is that development has stalled — the last meaningful update was several years ago. SpreadsheetLight using SpreadsheetLight; using var doc = new SLDocument(); doc.SetCellValue("A1", "Product"); doc.SetCellValue("B1", "Revenue"); doc.SetCellValue("C1", "Date"); doc.SetCellValue("A2", "Widget"); doc.SetCellValue("B2", 14999.99); doc.SetCellValue("C2", DateTime.Now.ToShortDateString()); doc.SaveAs("sales_spreadsheetlight.xlsx"); SpreadsheetLight izmanto vienu SLDocument klasi kā ievades punktu. SetCellValue metode ir pārslogota dažādiem tipiem. Tas, iespējams, ir vienkāršākais API šajā salīdzinājumā - bet vienkāršība nāk ar izmaksām. Strengths: MIT licensed, genuinely free Ļoti vienkāršs API, zemākā mācīšanās līkne šajā apkopojumā Lightweight, minimal dependencies (just OpenXML SDK) Basic chart support (more than ClosedXML offers) Good enough for simple reporting and data export tasks Limitations: Parādās neuzturēti, reti atjauninājumi, pēdējā lielā aktivitāte bija pirms gadiem .NET Framework focused, .NET Core/.NET 8+ compatibility is uncertain Tikai XLSX, bez XLS atbalsta Ierobežots funkciju kopums salīdzinājumā ar aktīvām alternatīvām Small community, limited Stack Overflow coverage and troubleshooting resources Vienkārši, vienreizēji tabulas ģenerēšanas uzdevumi .NET Framework projektos, kur jums ir nepieciešams kaut kas viegls un bezmaksas. Best for: 12. SpreadsheetGear — The Enterprise Veteran ir bijusi .NET Excel telpā vairāk nekā desmit gadus. tā sevi pozicionē kā augstas veiktspējas, Excel saderīgu aprēķinu mehānismu uzņēmējdarbības lietojumprogrammām. bibliotēka ietver diagrammu, formulu mehānismu ar 450+ funkcijām un WinForms/WPF rēķinu lapas vadīklas, lai izveidotu interaktīvus Excel līdzīgus lietojumprogrammas. SpreadsheetGear using SpreadsheetGear; IWorkbook wb = Factory.GetWorkbook(); IWorksheet ws = wb.Worksheets["Sheet1"]; IRange cells = ws.Cells; cells["A1"].Value = "Product"; cells["B1"].Value = "Revenue"; cells["C1"].Value = "Date"; cells["A2"].Value = "Widget"; cells["B2"].Value = 14999.99; cells["C2"].Value = DateTime.Now; cells["B2"].NumberFormat = "$#,##0.00"; wb.SaveAs("sales_spreadsheetgear.xlsx", FileFormat.OpenXMLWorkbook); SpreadsheetGear Output SpreadsheetGear's API closely mirrors the Excel VBA object model, developers who've written Excel macros will feel immediately at home. The Factory.GetWorkbook() pattern and IRange interface follow Excel's conventions closely. Strengths: 450+ built-in functions, one of the most complete formula engines in any .NET library Augstas veiktspējas aprēķini, kas optimizēti finanšu modelēšanas scenārijiem WinForms un WPF tabulas UI kontroles, lai izveidotu interaktīvas Excel līdzīgas saskarnes Excellent Excel compatibility, aims for pixel-perfect rendering Long track record, production-proven in enterprise environments Limitations: Higher price point (~$975/developer) with less visible pricing, must contact sales Smaller developer community than EPPlus, ClosedXML, or NPOI Mazāk mūsdienu API sajūta salīdzinājumā ar jaunākiem dalībniekiem Limited presence on modern community platforms (HackerNoon, Dev.to, etc.) Nav bezmaksas līmeņu vai kopienas izdevumu Finanšu lietojumprogrammas, kurām nepieciešama jaudīga aprēķinu sistēma, darbvirsmas lietojumprogrammas, kurām nepieciešama iebūvēta tabulas lietotāja interfeisa vadība, un uzņēmējdarbības vides, kurās izmanto Excel VBA migrāciju. Best for: Īpašības pārsteigums: ko katra bibliotēka faktiski var darīt? Beyond the basics of reading and writing cells, Excel libraries differ dramatically in their advanced feature support. Here's what we found when we tested features that matter in production applications. Atbalsts failu formātam Library XLSX XLS XLSB XLSM CSV TSV JSON ODS PDF Export IronXL ✅ ✅ ❌ ✅ ✅ ✅ ✅ ❌ ❌ EPPlus ✅ ❌ ❌ ✅ ✅ ❌ ❌ ❌ ❌ ClosedXML ✅ ❌ ❌ ✅ ✅ ❌ ❌ ❌ ❌ NPOI ✅ ✅ ❌ ❌ ❌ ❌ ❌ ❌ ❌ Aspose.Cells ✅ ✅ ✅ ✅ ✅ ✅ ✅ ✅ ✅ Syncfusion ✅ ✅ ❌ ✅ ✅ ✅ ✅ ❌ ✅ GemBox ✅ ✅ ✅ ✅ ✅ ✅ ❌ ✅ ✅ OpenXML SDK ✅ ❌ ❌ ✅ ❌ ❌ ❌ ❌ ❌ ExcelDataReader ✅ ✅ ❌ ❌ ✅ ❌ ❌ ❌ ❌ Spire.XLS ✅ ✅ ✅ ✅ ✅ ❌ ❌ ✅ ✅ SpreadsheetLight ✅ ❌ ❌ ❌ ✅ ❌ ❌ ❌ ❌ SpreadsheetGear ✅ ✅ ❌ ❌ ✅ ❌ ❌ ❌ ✅ IronXL ✅ ✅ ❌ ✅ ✅ ✅ ✅ ❌ ❌ EPPlus ✅ ❌ ❌ ✅ ✅ ❌ ❌ ❌ ❌ SlēgtXML ✅ ❌ ❌ ✅ ✅ ❌ ❌ ❌ ❌ Nākamais ✅ ✅ ❌ ❌ ❌ ❌ ❌ ❌ ❌ Aspose.Cells ✅ ✅ ✅ ✅ ✅ ✅ ✅ ✅ ✅ Sinfūzija ✅ ✅ ❌ ✅ ✅ ✅ ✅ ❌ ✅ Gembox ✅ ✅ ✅ ✅ ✅ ✅ ❌ ✅ ✅ OpenXML SDK atvēršana ✅ ❌ ❌ ✅ ❌ ❌ ❌ ❌ ❌ ExcelDataReader ✅ ✅ ❌ ❌ ✅ ❌ ❌ ❌ ❌ Spēle.xls ✅ ✅ ✅ ✅ ✅ ❌ ❌ ✅ ✅ SpreadsheetLight ✅ ❌ ❌ ❌ ✅ ❌ ❌ ❌ ❌ Izplatītājs ✅ ✅ ❌ ❌ ✅ ❌ ❌ ❌ ✅ The format support gap is significant. If you need par brīvu, NPOI ir jūsu vienīgā reālā iespēja. , jūs meklējat Aspose.Cells, Syncfusion, GemBox, Spire.XLS vai SpreadsheetGear, visi komerciāli. IronXL spēks šeit ir vienotais API XLSX + XLS + CSV + TSV + JSON, praktiska kombinācija datu cauruļvadu darbam. XLS legacy support PDF export from Excel Diagrammas, pivot tabulas un uzlabotas funkcijas Library Charts Pivot Tables Cond. Formatting Data Validation Images Formula Engine IronXL ❌ ❌ ✅ ✅ ✅ ✅ (auto-recalc) EPPlus ✅ ✅ ✅ ✅ ✅ ✅ ClosedXML ❌ ✅ ✅ ✅ ✅ ✅ NPOI ✅ (basic) ❌ ✅ ✅ ✅ ✅ Aspose.Cells ✅ ✅ ✅ ✅ ✅ ✅ Syncfusion ✅ ✅ ✅ ✅ ✅ ✅ GemBox ✅ ✅ ✅ ✅ ✅ ✅ OpenXML SDK ✅ (manual XML) ✅ (manual XML) ✅ (manual XML) ✅ (manual XML) ✅ ❌ ExcelDataReader ❌ ❌ ❌ ❌ ❌ ❌ Spire.XLS ✅ ✅ ✅ ✅ ✅ ✅ SpreadsheetLight ✅ (basic) ❌ ✅ ✅ ✅ ✅ SpreadsheetGear ✅ ❌ ✅ ✅ ✅ ✅ (450+ functions) IronXL ❌ ❌ ✅ ✅ ✅ ✅ (auto-recalc) EPPlus ✅ ✅ ✅ ✅ ✅ ✅ ClosedXML ❌ ✅ ✅ ✅ ✅ ✅ NPOI ✅ (basic) ❌ ✅ ✅ ✅ ✅ Tīkls. šūnas ✅ ✅ ✅ ✅ ✅ ✅ Sinfūzija ✅ ✅ ✅ ✅ ✅ ✅ Gembox ✅ ✅ ✅ ✅ ✅ ✅ OpenXML SDK ✅ (manual XML) ✅ (mājas lapa XML) ✅ (manual XML) ✅ (mājas lapa XML) ✅ ❌ ExcelDataReader ❌ ❌ ❌ ❌ ❌ ❌ Spēle.xls ✅ ✅ ✅ ✅ ✅ ✅ Izplatītājs (pamatlīdzekļi) ❌ ✅ ✅ ✅ ✅ SpreadsheetGear ✅ ❌ ✅ ✅ ✅ ✅ (450+ funkcijas) Preces apraksts ir skaidrs, ja nepieciešams , you need EPPlus, Aspose.Cells, Syncfusion, GemBox, or Spire.XLS. IronXL and ClosedXML both lack chart creation — an honest limitation worth acknowledging. For read/write data work without charts, both offer cleaner APIs than the chart-capable alternatives. chart and pivot table creation Darbība: Benchmark rezultāti visā reālajā pasaulē Performance claims without methodology are marketing. Here's how we structured our tests, and the results will probably surprise you. Methodology Mēs vadījām standartizētu benchmark paketi 15 bibliotēkās (mūsu pamatā ir 12 plus) , un as bonus contenders). Rather than a single synthetic task, we tested four real-world operations that mirror what developers actually build with Excel libraries: SpreadCheetah MiniExcel Ātrums : Create a 12-month statement workbook with formulas and formatting Financial Report Generation : Build a 500-item, 3-warehouse tracking spreadsheet with cross-references Inventory Tracking Pārdošanas datu analīze: 10 000 darījumu apstrāde un ierakstīšana ar agregāciju Darbinieku atalgojuma apstrāde: 250 darbinieku atalgojuma darba grāmata ar aprēķinātiem laukiem Katrs tests izmērīja sienas pulksteņa izpildes laiku (ms) un maksimālo atmiņu (MB). Testus veica .NET 8 ar vairākām iterācijām; mēs ziņojam par ierakstītajām vērtībām no mūsu atsauces ierīces. Finanšu pārskatu sagatavošana (12 mēnešu pārskati) Rank Library Time (ms) Memory (MB) 1 SpreadCheetah 2.9 0.2 2 DevExpress 53.2 4.5 3 Aspose.Cells 55.5 0.25 4 Spire.XLS 80.3 1.2 5 OfficeIMO 257.6 2.1 6 IronXL 498.1 4.2 1 Izplatīšanās 2.9 0.2 2 DevExpress pārdošana 53.2 4.5 3 Aspose.Cells 55.5 0.25 4 Spire.XLS 80.3 1.2 5 Birojs 257.6 2.1 6 IronXL 498.1 4.2 SpreadCheetah 2.9ms ir pārsteidzošs, tas ir tikai rakstīšanas, tikai uz priekšu straumēšanas bibliotēka, kas ir skaidri izstrādāta maksimālajai caurlaidībai. Tā upurē API ērtību (nav nejaušas šūnu piekļuves, nav lasīšanas) par neapstrādātu ātrumu. Par tīru ziņojumu ģenerāciju, kur jūs zināt izejas struktūru uz priekšu, tas būtībā ir neuzvarams. Aspose.Cells un DevExpress klasteris ir cieši 53-56ms diapazonā, kas pārstāv augstāko līmeni starp pilnvērtīgām bibliotēkām. IronXL ir šeit 498ms. Vienreizējam ikmēneša ziņojumam tas ir nepamanāms gala lietotājam. Par partijas darbu, kas rada tūkstošiem ziņojumu, tas kļūst par apsvērumu, un SpreadCheetah vai Aspose.Cells būtu labāka izvēle šim konkrētajam darba slodzei. Inventāra izsekošana (500 preču, 3 noliktavas) Rank Library Time (ms) Memory (MB) 1 EPPlus 51.2 2.9 2 ExcelMapper 54.1 4.9 3 SpreadCheetah 56.3 2.1 4 Aspose.Cells 136.5 2.4 5 Spire.XLS 183.2 1.4 6 DevExpress 451.7 5.0 7 IronXL 1,344.5 18.7 8 OfficeIMO 16,659.5 14.4 1 EPPlus 51.2 2.9 2 ExcelMapper 54.1 4.9 3 Izplatīšanās 56.3 2.1 4 Tīkls. šūnas 136.5 2.4 5 Spēle.xls 183.2 1.4 6 DevExpress pārdošana 451.7 5.0 7 IronXL 1,344.5 18.7 8 OfficeIMO 16 659 5 14.4 EPPlus dominē šajā vidējā sarežģītības darbībā, kam cieši seko SpreadCheetah un ExcelMapper. Atmiņas numuri stāsta svarīgu stāstu: Spire.XLS sasniedz konkurētspējīgu ātrumu tikai ar 1,4 MB, kas ir vislielākais atmiņas efektivitātes rezultāts šim testam. IronXL 18.7 MB pēdas nospiedums 7. pozīcijā atspoguļo tās DOM arhitektūru, ielādējot pilnu dokumentu modeli atmiņā. Sales Data Analysis (10,000 Transactions) This is the heaviest test, 10,000 rows with aggregation. It separates libraries built for scale from those optimized for convenience. Rank Library Time (ms) Memory (MB) 1 CsvHelper 140.3 9.3 2 ClosedXML 262.5 16.4 3 SpreadCheetah 289.7 15.9 4 FastExcel 346.7 13.8 5 MiniExcel 638.3 17.7 6 EPPlus 671.0 21.3 7 Aspose.Cells 696.5 15.3 8 NPOI 1,930.4 35.0 9 Spire.XLS 2,015.5 26.8 10 DevExpress 4,860.6 25.0 11 IronXL 11,322.9 80.9 1 Lāčplēša 140.3 9.3 2 ClosedXML 262.5 16.4 3 SpreadCheetah 289.7 15.9 4 Ātrums 346.7 13.8 5 MiniExcel 638.3 17.7 6 EPPlus 671.0 21.3 7 Tīkls. šūnas 696.5 15.3 8 Nākamais 1 030 4 35.0 9 Spēle.xls 2 015 5 26.8 10 DevExpress pārdošana 4 606 6 25.0 11 IronXL 11,322.9 80.9 Būsim godīgi: IronXL beidzas pēdējais šajā testā, un atšķirība ir ievērojama. 11.3 sekundēs un 80.9 MB, tas ir 80x lēnāks nekā CsvHelper un 43x lēnāks nekā ClosedXML. CsvHelper uzvar, jo tas ir mērķtiecīgi izveidots CSV analizators - nevis pilna Excel bibliotēka - un izvairās no OOXML dokumentu būvniecības pārslodzes. Praktiskā nozīme: ja jūs veidojat datu cauruļvadu, kas atkārtoti apstrādā vairāk nekā 10 000 darījumu datu kopumu, IronXL nav pareizais rīks šim konkrētajam darbam. EPPlus, ClosedXML vai straumēšanas bibliotēka, piemēram, SpreadCheetah, jums kalpos ievērojami labāk. Darbinieku atalgojuma apstrāde (250 darbinieki) Tikai trīs bibliotēkas veiksmīgi pabeidza šo sarežģīto, daudzslāņu darbību: Rank Library Time (ms) Memory (MB) 1 Aspose.Cells 404.0 3.8 2 IronXL 2,893.0 12.5 3 Spire.XLS 4,323.0 N/A* 1 Tīkls. šūnas 404.0 3.8 2 IronXL 2,893.0 12.5 3 Spēle.xls 4,323.0 N/A* Spire.XLS reported negative memory measurement — likely a measurement artifact. Lielākā daļa bibliotēku ne mēģināja šo testu vai neizdevās to pabeigt. fakts, ka tikai trīs bibliotēkas guvušas panākumus, runā par daudzslāņu, formulu smagu darba grāmatu ar aprēķinātiem laukiem sarežģītību. Aspose.Cells vada pārliecinoši. IronXL beidzas otrā, lēnāk, bet tas veiksmīgi pabeidza operāciju un radīja pareizu izeju, ko lielākā daļa konkurentu nevarēja pārvaldīt. Ko benchmarks mums saka (un ko viņi nedara) No šiem datiem izriet trīs modeļi. SpreadCheetah parādās top 3 katrā testā, ko tas ievadīja, bet tas nevar izlasīt failus, nevar izdarīt nejaušu šūnu piekļuvi un nevar piemērot sarežģītu formatēšanu pēc rakstīšanas. Aspose.Cells, EPPlus un Spire.XLS parasti tirdzniecības pozīcijas atkarībā no darbības veida. . Its DOM-based architecture and high-level API abstractions introduce overhead that shows up at scale, the tradeoff for that clean 3-line API you saw in the introduction. streaming/write-only libraries dominate speed benchmarks full-featured commercial libraries cluster together IronXL's performance profile favors simplicity over speed In practice, most business applications process well under 10,000 rows. A monthly sales report with 500 rows, a quarterly export with 2,000 transactions, an inventory snapshot with a few hundred SKUs, these workloads run comfortably on any library in this comparison, IronXL included. The performance differences become decision-relevant only at scale, and even then, the right response is often to choose the right tool for each specific job rather than forcing a single library to handle everything. Pārplatīšanas atbalsts: vai tas darbosies Linux, Docker un mākonī? Ja jūsu lietojumprogramma tiek izvietota Docker konteineros, Azure App Service Linux vai AWS Lambda, jūsu Excel bibliotēkai jāstrādā bez Windows specifiskām atkarībām. Library Windows Linux macOS Docker Azure App Svc AWS Lambda Blazor WASM IronXL ✅ ✅ ✅ ✅ ✅ ✅ ❌ EPPlus ✅ ✅ ✅ ✅ ✅ ✅ ❌ ClosedXML ✅ ✅ ✅ ✅ ✅ ✅ ❌ NPOI ✅ ✅ ✅ ✅ ✅ ✅ ❌ Aspose.Cells ✅ ✅ ✅ ✅ ✅ ✅ ❌ Syncfusion ✅ ✅ ✅ ✅ ✅ ✅ ✅ (server) GemBox ✅ ✅ ✅ ✅ ✅ ✅ ❌ OpenXML SDK ✅ ✅ ✅ ✅ ✅ ✅ ✅ ExcelDataReader ✅ ✅ ✅ ✅ ✅ ✅ ❌ Spire.XLS ✅ ✅ ✅ ✅ ✅ ⚠️ ❌ SpreadsheetLight ✅ ⚠️ ⚠️ ⚠️ ⚠️ ❌ ❌ SpreadsheetGear ✅ ✅ ✅ ✅ ✅ ✅ ❌ Ironisks ✅ ✅ ✅ ✅ ✅ ✅ ❌ Epipēds ✅ ✅ ✅ ✅ ✅ ✅ ❌ SlēgtXML ✅ ✅ ✅ ✅ ✅ ✅ ❌ NPOI ✅ ✅ ✅ ✅ ✅ ✅ ❌ Tīkls. šūnas ✅ ✅ ✅ ✅ ✅ ✅ ❌ Sinfūzija ✅ ✅ ✅ ✅ ✅ ✅ (serveris) Gembox ✅ ✅ ✅ ✅ ✅ ✅ ❌ OpenXML SDK atvēršana ✅ ✅ ✅ ✅ ✅ ✅ ✅ ExcelDataReader ✅ ✅ ✅ ✅ ✅ ✅ ❌ Spēle.xls ✅ ✅ ✅ ✅ ✅ ️ ❌ Izplatītājs ✅ ️ ️ ️ ⚠️ ❌ ❌ SpreadsheetGear ✅ ✅ ✅ ✅ ✅ ✅ ❌ Labā ziņa: lielākā daļa mūsdienu aktīvi uzturēto bibliotēku darbojas starp platformām .NET 8+. SpreadsheetLight ir ārējais, tā .NET Framework fokuss padara starpplatformu izvietošanu neuzticamu. (renderēšanas dzinējs ir pārāk smags), bet Blazor servera pusē darbojas labi ar visiem tiem. Klientu puse Visas bibliotēkas, kuru mērķis ir vai .NET 6+ darbojas minimālajos Docker konteineros ( Nav nepieciešamas native OS atkarības, atšķirībā no PDF bibliotēkām, Excel bibliotēkas ir tīrs pārvaldītais kods. Docker consideration .NET Standard 2.0 mcr.microsoft.com/dotnet/treniņu laiks: 8.0 Licencēšana un cenu noteikšana: cik tas faktiski maksās jūsu komandai? Licencēšana ir vieta, kur Excel bibliotēkas dramatiski atšķiras. Atvērtā koda iespējas Library License Commercial Use Gotchas ClosedXML MIT ✅ Free No commercial support; community-only fixes NPOI Apache 2.0 ✅ Free Must include license notice; no commercial support OpenXML SDK MIT ✅ Free Microsoft-maintained, but no dedicated Excel support ExcelDataReader MIT ✅ Free Read-only; you'll need another library for writes SpreadsheetLight MIT ✅ Free Appears unmaintained; risk of unpatched bugs ClosedXML ar Bezmaksas Nav komerciāla atbalsta; tikai kopienas fiksē Nākamais Apache 2.0 lietošana Bezmaksas Must include license notice; no commercial support OpenXML SDK atvēršana ar Bezmaksas Microsoft uzturēts, bet bez īpaša Excel atbalsta ExcelDataReader ar Bezmaksas Lasīt tikai; jums būs nepieciešama cita bibliotēka rakstīšanai SpreadsheetLight ar Bezmaksas Izskatās neapkopoti; risks, ka kļūdas netiks pielāgotas "Bezmaksas" bibliotēkām ir slēptas izmaksas: nav SLA atbalstītu atbalstu, nav garantētas fiksācijas grafiku, un inženiertehnisko laiku jūsu komanda tērē problēmu novēršanas jautājumiem, ko komerciāls piegādātājs risinātu. par hobiju projektiem un prototipiem, šīs izmaksas ir pieņemamas. un abiem atļauj neierobežotu komerciālu izmantošanu, atšķirība ir provides versus what a vendor guarantees. ar licenci Apache 2.0 licencēšana Kopiena Komerciālās iespējas salīdzinājumā Library Entry Price Per-Dev Pricing Free Tier OEM/SaaS Extra Support Included IronXL $749/yr (Lite) $749–$2,999/yr 30-day trial Yes (add-on) ✅ 24/5 engineering EPPlus $299/yr (base) $299–$599/yr v4.5.3 (outdated) Yes (add-on) ✅ Email Aspose.Cells $1,199/yr $1,199–$11,198/yr Eval (watermark) Yes (expensive) ✅ Priority Syncfusion $0–$995/yr Per-suite Community License* Included in suite ✅ (paid tiers) GemBox ~$890 (one-time) Per-developer 150 rows free One-time ✅ 12 months Spire.XLS ~$999/dev Per-developer 200 rows/5 sheets Add-on ✅ Email SpreadsheetGear ~$975/dev Per-developer None Contact sales ✅ Email IronXL $749/yr (Lite) $ 749 – $ 2,999 / mēnesis 30 dienu tiesas prāva Jā (papildināts ar) 24 / 5 inženierzinātne Epipēds $ 299 / mēnesis (bāze) $299–$599/yr v4.5.3 (outdated) Jā (papildināts ar) Šī e-pasta adrese Tīkls. šūnas $ 1,199 / mēnesis $1,199–$11,198/yr Eval (ūdens zīme) Jā (tā ir dārga) ✅ Priority Sinfūzija $0 – $995 / mēnesis pēc sekām Kopienas licences * Iekļauts suite ✅ (atmaksātie maksājumi) Gembox ~890 ASV dolāri (vienreizējs) Per-attīstītājs 150 rubļi bez maksas Vienreizējs 12 mēneši Spēle.xls ~999 ASV dolāri/dev Per-attīstītājs 200 rindas / 5 loksnes Papildinājums Šī e-pasta adrese Izplatītājs ~975 ASV dolāri/dev Per-attīstītājs Neviens Pārdošanas kontakts Šī e-pasta adrese Syncfusion kopienas licence: bez maksas uzņēmumiem ar gada bruto ieņēmumiem < 1M $ un ≤ 5 izstrādātājiem. deserves a note. EPPlus was MIT-licensed through version 4.5.3 (2018). Version 5 switched to Polyform Noncommercial, and later versions require a commercial license for any commercial use. Many legacy projects still reference 4.5.3, if that's you, know that you're running on an unmaintained version with unpatched bugs. Migrating to EPPlus 7+ requires purchasing a license; migrating to ClosedXML or IronXL is an alternative path. The EPPlus licensing story Ironija Iron Suite – visi 10 Iron Software produkti kopā – piedāvā ievērojamus ietaupījumus, ja jums ir nepieciešamas arī PDF, OCR vai svītrkodu iespējas. Licencēšana trešajām personām .NET saderība: no Framework līdz .NET 10 .NET ekosistēma ir fragmentēta dažādās versijās, un ne visas bibliotēkas ir saglabājušās. Library .NET Framework 4.x .NET Core 3.1 .NET 6 .NET 8 (LTS) .NET 9 .NET 10 .NET Standard 2.0 IronXL ✅ ✅ ✅ ✅ ✅ ✅ ✅ EPPlus ✅ ✅ ✅ ✅ ✅ ✅ ✅ ClosedXML ✅ ✅ ✅ ✅ ✅ ✅ ✅ NPOI ✅ ✅ ✅ ✅ ✅ ✅ ✅ Aspose.Cells ✅ ✅ ✅ ✅ ✅ ✅ ✅ Syncfusion ✅ ✅ ✅ ✅ ✅ ✅ ✅ GemBox ✅ ✅ ✅ ✅ ✅ ✅ ✅ OpenXML SDK ✅ ✅ ✅ ✅ ✅ ✅ ✅ ExcelDataReader ✅ ✅ ✅ ✅ ✅ ✅ ✅ Spire.XLS ✅ ✅ ✅ ✅ ✅ ✅ ✅ SpreadsheetLight ✅ ⚠️ ⚠️ ⚠️ ❌ ❌ ❌ SpreadsheetGear ✅ ✅ ✅ ✅ ✅ ✅ ✅ Ironisks ✅ ✅ ✅ ✅ ✅ ✅ ✅ Epipēds ✅ ✅ ✅ ✅ ✅ ✅ ✅ SlēgtXML ✅ ✅ ✅ ✅ ✅ ✅ ✅ Nākamais ✅ ✅ ✅ ✅ ✅ ✅ ✅ Tīkls. šūnas ✅ ✅ ✅ ✅ ✅ ✅ ✅ Sinfūzija ✅ ✅ ✅ ✅ ✅ ✅ ✅ Gembox ✅ ✅ ✅ ✅ ✅ ✅ ✅ OpenXML SDK atvēršana ✅ ✅ ✅ ✅ ✅ ✅ ✅ ExcelDataReader ✅ ✅ ✅ ✅ ✅ ✅ ✅ Spēle.xls ✅ ✅ ✅ ✅ ✅ ✅ ✅ Izplatītājs ✅ ️ ️ ️ ❌ ❌ ❌ Izplatītājs ✅ ✅ ✅ ✅ ✅ ✅ ✅ Visas pārējās bibliotēkas mērķtiecīgi izmanto .NET Standard 2.0 (kas aptver .NET Framework 4.6.1+ un visas .NET Core/.NET 5+ versijas) vai nodrošina multi-targeted paketes. Visas 11 aktīvi uzturētās bibliotēkas to pilnībā atbalsta. For new projects in 2026, target . .NET 8 (LTS) tīkls .NET 8 (LTS) tīkls IronXL kuģi ikmēneša atjauninājumus. EPPlus, Aspose.Cells un Syncfusion izlaišanas ceturkšņi. ClosedXML un NPOI ir neregulāras, bet biežas kopienas virzītas izlaišanas. SpreadsheetLight nav bijis nozīmīgs atjauninājums gadiem, sarkanā karoga ilgtermiņa pieņemšanu. Release cadence as a longevity signal: Migrācija no Excel Interop – kopīgais sākuma punkts Many teams arrive at this comparison because they're migrating away from Microsoft.Office.Interop.Excel. If that's you, here's the quick playbook. Interop requires Office installed on every machine that runs your code, including servers. That was tolerable on a single Windows Server, but it breaks the moment you containerize, scale horizontally, or deploy to Linux. Migrācijas modelis ir vienkāršs neatkarīgi no tā, kuru bibliotēku izvēlaties: // Step 1: Remove COM references // Delete: Microsoft.Office.Interop.Excel references from your .csproj // Step 2: Install replacement via NuGet // PM> Install-Package IronXL.Excel (or EPPlus, ClosedXML, etc.) // Step 3: Replace Interop patterns // Interop: xlApp.Workbooks.Add() → IronXL: WorkBook.Create() // Interop: ws.Cells[1,1] = value → IronXL: ws["A1"].Value = value // Interop: wb.SaveAs(path) → IronXL: wb.SaveAs(path) // Step 4: Remove COM cleanup code // Delete: Marshal.ReleaseComObject() calls — no longer needed Lielākais ieguvums ir ne tikai starpplatformu izvietošana, bet arī COM tīrīšanas galvassāpju novēršana.Ne vairāk bāreņu EXCEL.EXE procesus, ne vairāk Marshal.ReleaseComObject() zvanus, ne vairāk atmiņas noplūdes no neatbrīvotām COM atsaucēm.Katra bibliotēka šajā salīdzinājumā pārvalda savus resursus, izmantojot standarta .NET IDisposable modeļus. Kura C# Excel bibliotēka ir piemērota jūsu projektam? Pēc tam, kad pārbaudījām visas 12 bibliotēkas, šeit ir mūsu godīgie norādījumi, kas sakārtoti pēc scenārija. Mēs nevēlamies izlikties, ka IronXL ir labākā izvēle katrai situācijai, tā nav. Labākais budžeta apzinātiem projektiem ir skaidrs uzvarētājs komandām, kurām nepieciešamas pilnas lasīšanas / rakstīšanas spējas ar nulles budžetu. MIT licence, aktīva attīstība, intuitīvs API. Kompromiss: nav grafiku, un veiktspēja samazinās virs 50K rindām. ir runner-up, it īpaši, ja jums ir nepieciešams XLS mantojuma atbalstu. ClosedXML NPOI Labākais uzņēmējdarbības pielietojumiem vai IronXL piedāvā tīrāku API un zemāku cenu punktu, kad nav nepieciešami diagrammas un pīlāri, tas izceļas ar datu cauruļvadu darbu, ziņojumu izveidi un krustenisko formātu konversiju. Aspose.Cells ir pareizā izvēle, kad jums ir nepieciešama katra Excel funkcija zem saules un budžets nav ierobežojums. IronXL Aspose.Cells RuralCo integrētais IronXL Labākais augstas veiktspējas / lieliem datu kopumiem was the standout performer in our benchmarks, consistently top-3 across every operation, with a stunning 2.9ms for financial report generation. It's write-only and forward-only, but if that fits your use case, nothing else comes close. Among full-featured libraries, un konsekventi novietoti augšējā līmenī. tikai lasāmam augstas veiktspējas uzņemšanai, ar savu straumēšanas IDataReader saskarne ir nepārspējama. SpreadCheetah Aspose.Cells EPPlus ExcelDataReader Labākie lasāmie scenāriji Tas ir MIT licencēts, viegls, ātrs, un natively integrējas ar System.Data.DataTable. Ja jums vienkārši ir nepieciešams ievadīt datus tabulā, pievienojot pilnu lasīt / rakstīt bibliotēku nav nepieciešams. ExcelDataReader Labākais maksimālā funkciju seguma nodrošināšanai vai Atbalsta gan diagrammas, pivot tabulas, sparklīnus, nosacītu formatēšanu, datu validāciju, VBA un PDF eksportu.Syncfusion bezmaksas kopienas licence ļauj mazām komandām bez maksas piekļūt uzņēmuma funkcijām, pārbaudiet, vai jums ir tiesības. Aspose.Cells Syncfusion XlsIO Labākā pieredze izstrādātājiem vai piedāvā visintuitīvākos API ar vismazāko katla plātni. Abi ļauj jums pāriet no Install-Package uz darbīgu Excel failu zem 5 koda līnijām. IronXL pievieno krusteniskā formāta atbalstu (XLS + XLSX + CSV + JSON) un profesionālu atbalstu; ClosedXML pievieno MIT licencēšanu un lielāku kopienu. IronXL ClosedXML Lasot Excel failus: otra puse no vienādojuma Lielākā daļa bibliotēkas vērtējumu ir vērsti uz Šeit ir, kā lasīšanas pieredze salīdzina četrās populārās bibliotēkās, visas veicot to pašu uzdevumu: ielādēt esošo Excel failu, iterēt pa rindām un iegūt ievadītos datus. Rakstīt // ExcelDataReader — streaming, read-only, lowest overhead using var stream = File.Open("report.xlsx", FileMode.Open, FileAccess.Read); using var reader = ExcelReaderFactory.CreateReader(stream); while (reader.Read()) { string product = reader.GetString(0); double revenue = reader.GetDouble(1); } // IronXL — concise cell-addressing syntax WorkBook wb = WorkBook.Load("report.xlsx"); WorkSheet ws = wb.DefaultWorkSheet; foreach (var row in ws.Rows.Skip(1)) // skip header { string product = row.Columns[0].StringValue; double revenue = row.Columns[1].DoubleValue; } // ClosedXML — similar pattern, IXLRow interface using var wb = new XLWorkbook("report.xlsx"); var ws = wb.Worksheet(1); foreach (var row in ws.RowsUsed().Skip(1)) { string product = row.Cell(1).GetString(); double revenue = row.Cell(2).GetDouble(); } // EPPlus — row/column indexed access using var package = new ExcelPackage(new FileInfo("report.xlsx")); var ws = package.Workbook.Worksheets[0]; for (int r = 2; r <= ws.Dimension.End.Row; r++) { string product = ws.Cells[r, 1].GetValue<string>(); double revenue = ws.Cells[r, 2].GetValue<double>(); } ExcelDataReader izmanto tikai IDataReader paraugu uz priekšu, jūs nevarat pāriet uz konkrētu šūnu vai doties atpakaļ. Tas ir ātrākais un vieglākais variants secīgai lasīšanai. IronXL un ClosedXML gan piedāvā priekšgalu pār rindām ar ievadīto šūnu piekļuvi, lai gan to sintakse atšķiras. EPPlus izmanto veselu rindu / kolonnas adresēšanu, kas ir verbozs, bet skaidrs. Visas četras pieejas darbojas, izvēle ir atkarīga no tā, vai jums ir nepieciešama nejauša piekļuve (IronXL, ClosedXML, EPPlus) vai tikai secīga straumēšana (ExcelDataReader). Nosaukums oriģinālvalodā: Libraries Worth Watching Mūsu atsauces testa rezultāti parādīja trīs bibliotēkas, kas nav mūsu 12 pamatā, bet ir pelnījušas uzmanību. ir tikai rakstīšanas, tikai uz priekšu straumēšanas bibliotēka, kas dominēja mūsu ātruma kritērijus, 2.9ms finanšu pārskatu ģenerēšanai, konsekventi top-3 katrā testā. Izplatīšanās Izplatīšanās koncentrējas uz zemas atmiņas lasīšanu un rakstīšanu, izmantojot straumēšanu. Tā ieņem piekto vietu pārdošanas datu analīzē (638ms, 17.7MB), konkurējot ar EPPlus un Aspose.Cells. Tās API ir nekonvencionāla (liels anonīmu tipu un vārdnīcu lietojums), bet tā ir MIT licencēta un aktīvi uzturēta. Īpaši noderīga atmiņas ierobežotām vidēm, piemēram, Azure Functions. Miniatūra Miniatūra ir viegls XLSX lasītājs / rakstītājs, kas ieņēma 4. vietu pārdošanas datu analīzē (347ms, 13.8MB). Tas ir mazāk pazīstams, bet nodrošina stabilu veiktspēju ar minimālu pēdu. Ātrums Ātrums Common Gotchas: Pitfalls Katrs izstrādātājs hit Pēc tam, kad strādājām ar visām 12 bibliotēkām (un trim bonusa konkurentiem), mēs apkopojām problēmas, kas visbiežāk sastopas ar izstrādātājiem. Kodēšanas lamatas uz .NET Core ExcelDataReader, NPOI un vairākas citas bibliotēkas prasa reģistrēt kodu lapu kodēšanas pakalpojumu sniedzēju pirms XLS (binārā) failu lasīšanas .NET Core: // Add this ONCE at application startup — before any Excel operations System.Text.Encoding.RegisterProvider(System.Text.CodePagesEncodingProvider.Instance); Bez šīs līnijas jūs saņemsiet NotSupportedException par kodēšanu 1252. Tas ietekmē tikai XLS (ne tikai XLSX), tikai .NET Core/.NET 5+, un kļūdas ziņojums skaidri nenorāda uz risinājumu. Darbojas visās bibliotēkās Excel datumus uzglabā kā plūstošos punktus (datumus kopš 1900. gada 1. janvāra). Katra bibliotēka tos nedaudz atšķiras no datuma datuma datuma datuma datuma datuma datuma datuma datuma datuma datuma datuma datuma. Mūsu ieteikums: vienmēr apstipriniet datuma braucienus (rakstīt → saglabāt → pārlādēt → lasīt) ar savu konkrēto bibliotēku, pirms uzticaties datuma apstrādei ražošanā. 1900 lēciens gads bug Atmiņas noplūdes no neapstrādātām darba grāmatām Vairākas bibliotēkas īsteno IDisposable, ClosedXML, EPPlus, SpreadsheetLight un OpenXML SDK starp tām. Aizmirst izmantot paziņojumus var izraisīt atmiņas noplūdes, kas tikai virsmas zem slodzes. IronXL, NPOI, un Aspose.Cells apstrādā tīrīšanu atšķirīgi (finalizers vai skaidri Close() metodes). Visdrošākais modelis visās bibliotēkās: // Always wrap in using — even if the library doesn't strictly require it using var wb = /* load or create workbook */; // ... work with workbook ... // Disposal happens automatically at scope exit EPPlus licences konteksta prasības EPPlus 5+ nosūtīs licences izņēmumu pirmajā API zvanī, ja neesat iestatījis licences kontekstu. // Required before ANY EPPlus operations in v5+ ExcelPackage.License.SetNonCommercialOrganization("Org Name"); // or: ExcelPackage.License.SetLicenseKey("your-key"); Liels failu OOM 32-bitu procesos Ja jūsu lietojumprogramma darbojas kā 32 bitu process (pārbaudiet IntPtr.Size == 4), DOM balstītas bibliotēkas nokļūs OutOfMemoryException daudz agrāk, bieži vien aptuveni 20 000-30 000 rindās atkarībā no kolonnas skaita. Ko darīt tālāk .NET Excel bibliotēku ekosistēma ir veselīga, konkurētspējīga un aktīvi attīstās. nav vienas "labākās" bibliotēkas, tikai labākā bibliotēka Projekts, jūsu budžets un jūsu izvietošanas mērķi. Jūsu Mūsu ieteikums: izvēlieties 2-3 kandidātus no šīs salīdzināšanas, instalējiet tos, izmantojot NuGet, un izveidojiet nelielu prototipu pret jūsu faktiskajiem datiem. Edge gadījumi, apvienotās šūnas, formulas, lieli faili, īpašas formatēšanas prasības, jo tur parādās reālās atšķirības. Jūsu Īpaši attiecībā uz IronXL, , un nodrošināt darba paraugus, kas aptver visbiežāk sastopamos scenārijus. a Ļauj testēt ražošanu bez ūdens zīmēm. Sākt dokumentāciju Koda piemēri Tutoriāli 30 dienu bezmaksas izmēģinājums Mēs atjaunināsim šo salīdzinājumu, kad bibliotēkas izlaiž jaunas versijas - .NET ekosistēma kustas ātri, un mēs vēlamies, lai tas paliktu resurss, ko mēs vēlējāmies. Komandas, kas apsver Tas ir labākais veids, kā novērtēt, vai tas atbilst jūsu faktiskajai darba plūsmai.Testējiet to ar savām tabulām, formām, formatēšanu un izvietošanas vidi, lai redzētu, kā tas darbojas praksē, pirms pāriet uz priekšu ar ražošanas licenci. IronXL, 30 dienu bezmaksas izmēģinājuma versija Biežāk uzdotie jautājumi Šie ir jautājumi, kurus mēs visbiežāk redzam no izstrādātājiem, kas izvērtē C# Excel bibliotēkas. How do I create an Excel file in C# without Microsoft Office installed? Katra bibliotēka šajā salīdzinājumā, izņemot Microsoft.Office.Interop.Excel (ko mēs apzināti izslēdzām) darbojas bez Office. , , , utt. - un jūs varat izveidot, lasīt un rakstīt XLSX failus mašīnās bez Office instalēšanas, ieskaitot Linux serverus un Docker konteinerus. Instalācijas pakete IRONXL.Excel Instalācijas pakete EPPlus Instalācijas pakete ClosedXML Is EPPlus still free for commercial use? EPPlus versija 5 (izlaists 2020. gadā) un vēlāk nepieciešama komerciāla licence jebkādai komerciālai lietošanai. Pēdējā bezmaksas versija ir 4.5.3, kas nav uzturēta un trūkst gadu garu kļūdu labojumu un drošības uzlabošanas. What's the fastest .NET Excel library for large datasets? Mūsu rakstīšanas kritērijos GemBox.Spreadsheet un SpreadsheetGear konsekventi vada 100K+ rindu rakstīšanu. Lielo failu lasīšanas tikai lietošanai ExcelDataReader straumēšanas IDataReader interfeiss ir vislielākā atmiņas efektivitāte. OpenXML SDK piedāvā zemāko atmiņas slieksni, izmantojot SAX rakstītāju, bet prasa ievērojami vairāk koda. Which libraries support legacy XLS (97-2003) format? IronXL, NPOI, Aspose.Cells, GemBox.Spreadsheet, ExcelDataReader (tikai lasīšanai), Spire.XLS un SpreadsheetGear visi atbalsta bināro XLS formātu. Can these libraries run in Docker containers on Linux? Jā — visas aktīvi uzturētās bibliotēkas (11 no 12, izņemot SpreadsheetLight) darbojas standarta .NET 8 Docker konteineros Linux bez nativām atkarībām. Atšķirībā no PDF atskaņošanas bibliotēkām, kurām dažreiz ir nepieciešami sistēmas fonti vai pārlūkprogrammu dzinēji, Excel bibliotēkas ir tīrs pārvaldīts kods. Pietiek ar minimālu mcr.microsoft.com/dotnet/runtime:8.0 bāzes attēlu. What's your experience? Which C# Excel library are you using in production, and what made you choose it? Drop your thoughts in the comments — we read every one.