Cómo Leer Archivos de Excel en C# (Tutorial para Desarrolladores)

Director de soluciones .NET trabajando con documentos Microsoft Excel IO
Christian Findlay
26 de mayo, 2019
Actualizado 10 de diciembre, 2024
Compartir:
This article was translated from English: Does it need improvement?
Translated
View the article in English

Este tutorial explica cómo leer un archivo Excel en C#, así como realizar tareas cotidianas como la validación de datos, la conversión de bases de datos, las integraciones Web API y la modificación de fórmulas. Este artículo hace referencia a ejemplos de código que utilizan la biblioteca IronXL .NET Excel.


Visión general

IronXL facilita la lectura y edición de documentos de Microsoft Excel con C#. IronXL no requiere Microsoft Excel ni Interop. De hecho, IronXL proporciona una API más rápida e intuitiva que Microsoft.Office.Interop.Excel.

IronXL Incluye:

  • Asistencia dedicada al producto por parte de nuestros ingenieros de .NET
  • Instalación sencilla mediante Microsoft Visual Studio
  • Prueba gratuita para el desarrollo. Licencias desde $749.

    Leer y crear archivos Excel en C# y VB.NET es fácil utilizando la librería de software IronXL.

Lectura de archivos .XLS y .XLSX de Excel con IronXL

A continuación se muestra un resumen del flujo de trabajo general para leer archivos de Excel utilizando IronXL:

  1. Instale la biblioteca IronXL Excel. Podemos hacer esto utilizando nuestro paquete NuGet o descargando el DLL de .Net Excel.

  2. Utilice el método WorkBook.Load para leer cualquier documento XLS, XLSX o CSV.

  3. Obtén valores de celdas usando una sintaxis intuitiva: sheet ["A11"].DecimalValue
:path=/static-assets/excel/content-code-examples/tutorials/how-to-read-excel-file-csharp-1.cs
using IronXL;
using System;
using System.Linq;

// Supported spreadsheet formats for reading include: XLSX, XLS, CSV and TSV
WorkBook workBook = WorkBook.Load("test.xlsx");
WorkSheet workSheet = workBook.WorkSheets.First();

// Select cells easily in Excel notation and return the calculated value
int cellValue = workSheet["A2"].IntValue;

// Read from Ranges of cells elegantly.
foreach (var cell in workSheet["A2:A10"])
{
    Console.WriteLine("Cell {0} has value '{1}'", cell.AddressString, cell.Text);
}

// Advanced Operations
// Calculate aggregate values such as Min, Max and Sum
decimal sum = workSheet["A2:A10"].Sum();

// Linq compatible
decimal max = workSheet["A2:A10"].Max(c => c.DecimalValue);
Imports IronXL
Imports System
Imports System.Linq

' Supported spreadsheet formats for reading include: XLSX, XLS, CSV and TSV
Private workBook As WorkBook = WorkBook.Load("test.xlsx")
Private workSheet As WorkSheet = workBook.WorkSheets.First()

' Select cells easily in Excel notation and return the calculated value
Private cellValue As Integer = workSheet("A2").IntValue

' Read from Ranges of cells elegantly.
For Each cell In workSheet("A2:A10")
	Console.WriteLine("Cell {0} has value '{1}'", cell.AddressString, cell.Text)
Next cell

' Advanced Operations
' Calculate aggregate values such as Min, Max and Sum
Dim sum As Decimal = workSheet("A2:A10").Sum()

' Linq compatible
Dim max As Decimal = workSheet("A2:A10").Max(Function(c) c.DecimalValue)
$vbLabelText   $csharpLabel

Los ejemplos de código utilizados en las siguientes secciones de este tutorial (junto con el código del proyecto de ejemplo) funcionarán en tres hojas de cálculo de Excel de muestra (ver abajo para un visual):

Vs Spreadsheets related to Lectura de archivos .XLS y .XLSX de Excel con IronXL


Tutorial

1. Descargue GRATIS la biblioteca IronXL C&num

Comience a usar IronXL en su proyecto hoy con una prueba gratuita.

Primer Paso:
green arrow pointer


Lo primero que necesitamos hacer es instalar la biblioteca IronXL.Excel, agregando funcionalidad de Excel al .NET framework.

La instalación de IronXL.Excel se logra más fácilmente utilizando nuestro paquete NuGet, aunque también puede optar por instalar manualmente el DLL en su proyecto o en su caché de ensamblados global.

Instalación del paquete NuGet de IronXL

  1. En Visual Studio, haz clic con el botón derecho en el proyecto y selecciona "Administrar paquetes NuGet...".

  2. Busque el paquete IronXL.Excel y haga clic en el botón Instalar para añadirlo al proyecto.

    Ef Nuget related to Instalación del paquete NuGet de IronXL

    Otra forma de instalar la librería IronXL es utilizando la Consola del Gestor de Paquetes NuGet:

  3. Acceda a la consola del gestor de paquetes

  4. Escribe > Install-Package IronXL.Excel
  PM > Install-Package IronXL.Excel

Además, puedes ver el paquete en el sitio web de NuGet

Instalación manual

Alternativamente, podemos comenzar descargando el DLL de .NET Excel de IronXL e instalándolo manualmente en Visual Studio.

2. Cargar un libro de Excel

La clase WorkBook representa una hoja de Excel. Para abrir un archivo de Excel usando C#, utilizamos el método WorkBook.Load, especificando la ruta del archivo de Excel.

:path=/static-assets/excel/content-code-examples/tutorials/how-to-read-excel-file-csharp-2.cs
WorkBook workBook = WorkBook.Load(@"Spreadsheets\\GDP.xlsx");
Dim workBook As WorkBook = WorkBook.Load("Spreadsheets\\GDP.xlsx")
$vbLabelText   $csharpLabel

Muestra: ExcelToDBProcessor

Cada WorkBook puede tener múltiples objetos WorkSheet. Cada uno de ellos representa una única hoja de cálculo del documento Excel. Utilice el método WorkBook.GetWorkSheet para obtener una referencia a una hoja de cálculo de Excel específica.


:path=/static-assets/excel/content-code-examples/tutorials/how-to-read-excel-file-csharp-3.cs

Muestra: ExcelToDB

Creación de nuevos documentos Excel

Para crear un nuevo documento de Excel, construya un nuevo objeto WorkBook con un tipo de archivo válido.

:path=/static-assets/excel/content-code-examples/tutorials/how-to-read-excel-file-csharp-4.cs
WorkBook workBook = new WorkBook(ExcelFileFormat.XLSX);
Dim workBook As New WorkBook(ExcelFileFormat.XLSX)
$vbLabelText   $csharpLabel

Muestra: ApiToExcelProcessor

Nota: Use ExcelFileFormat.XLS para soportar versiones antiguas de Microsoft Excel (95 y anteriores).

Añadir una hoja de cálculo a un documento Excel

Como se explicó anteriormente, un WorkBook de IronXL contiene una colección de uno o más WorkSheets.

Así es como se ve un libro de trabajo con dos hojas en Excel.

Este es el aspecto de un libro con dos hojas de cálculo en Excel.

Para crear un nuevo WorkSheet llame a WorkBook.CreateWorkSheet con el nombre de la hoja de trabajo.

:path=/static-assets/excel/content-code-examples/tutorials/how-to-read-excel-file-csharp-5.cs
WorkSheet workSheet = workBook.GetWorkSheet("GDPByCountry");
Dim workSheet As WorkSheet = workBook.GetWorkSheet("GDPByCountry")
$vbLabelText   $csharpLabel

3. Acceder a los valores de las celdas

Leer y editar una celda individual

El acceso a los valores de celdas individuales de la hoja de cálculo se realiza recuperando la celda deseada de su WorkSheet. como se muestra a continuación:

:path=/static-assets/excel/content-code-examples/tutorials/how-to-read-excel-file-csharp-16.cs
WorkBook workBook = WorkBook.Load("test.xlsx");
WorkSheet workSheet = workBook.DefaultWorkSheet;
IronXL.Cell cell = workSheet["B1"].First();
Dim workBook As WorkBook = WorkBook.Load("test.xlsx")
Dim workSheet As WorkSheet = workBook.DefaultWorkSheet
Dim cell As IronXL.Cell = workSheet("B1").First()
$vbLabelText   $csharpLabel

La clase Cell de IronXL representa una celda individual en una hoja de cálculo de Excel. Contiene propiedades y métodos que permiten a los usuarios acceder y modificar directamente el valor de la celda.

Cada objeto WorkSheet gestiona un índice de objetos Cell que corresponde a cada valor de celda en una hoja de cálculo de Excel. En el código fuente anterior, hacemos referencia a la celda deseada por su índice de fila y columna (la celda B1 en este caso) utilizando la sintaxis estándar de indexación de arreglos.

Con una referencia al objeto Cell, podemos leer y escribir datos desde y hacia una celda de la hoja de cálculo:

:path=/static-assets/excel/content-code-examples/tutorials/how-to-read-excel-file-csharp-17.cs
IronXL.Cell cell = workSheet["B1"].First();
string value = cell.StringValue;   // Read the value of the cell as a string
Console.WriteLine(value);

cell.Value = "10.3289";           // Write a new value to the cell
Console.WriteLine(cell.StringValue);
Dim cell As IronXL.Cell = workSheet("B1").First()
Dim value As String = cell.StringValue ' Read the value of the cell as a string
Console.WriteLine(value)

cell.Value = "10.3289" ' Write a new value to the cell
Console.WriteLine(cell.StringValue)
$vbLabelText   $csharpLabel

Leer y escribir un rango de valores de celda

La clase Range representa una colección bidimensional de objetos Cell. Esta colección se refiere a un rango literal de celdas de Excel. Obtenga rangos utilizando el indexador de cadenas en un objeto WorkSheet.

El texto del argumento es ya sea la coordenada de una celda (por ejemplo, "A1", como se mostró anteriormente) o un rango de celdas de izquierda a derecha de arriba a abajo (por ejemplo, "B2:E5"). También es posible llamar a GetRange en un WorkSheet.

:path=/static-assets/excel/content-code-examples/tutorials/how-to-read-excel-file-csharp-6.cs
Range range = workSheet["D2:D101"];
Dim range As Range = workSheet("D2:D101")
$vbLabelText   $csharpLabel

Muestra: DataValidation

Existen varias formas de leer o editar los valores de las celdas de un Rango. Si se conoce el recuento, utilice un bucle For.

:path=/static-assets/excel/content-code-examples/tutorials/how-to-read-excel-file-csharp-7.cs
// Iterate through the rows
for (var y = 2; y <= 101; y++)
{
    var result = new PersonValidationResult { Row = y };
    results.Add(result);

    // Get all cells for the person
    var cells = workSheet[$"A{y}:E{y}"].ToList();

    // Validate the phone number (1 = B)
    var phoneNumber = cells[1].Value;
    result.PhoneNumberErrorMessage = ValidatePhoneNumber(phoneNumberUtil, (string)phoneNumber);

    // Validate the email address (3 = D)
    result.EmailErrorMessage = ValidateEmailAddress((string)cells[3].Value);

    // Get the raw date in the format of Month Day[suffix], Year (4 = E)
    var rawDate = (string)cells[4].Value;
    result.DateErrorMessage = ValidateDate(rawDate);
}
' Iterate through the rows
For y = 2 To 101
	Dim result = New PersonValidationResult With {.Row = y}
	results.Add(result)

	' Get all cells for the person
	Dim cells = workSheet($"A{y}:E{y}").ToList()

	' Validate the phone number (1 = B)
	Dim phoneNumber = cells(1).Value
	result.PhoneNumberErrorMessage = ValidatePhoneNumber(phoneNumberUtil, CStr(phoneNumber))

	' Validate the email address (3 = D)
	result.EmailErrorMessage = ValidateEmailAddress(CStr(cells(3).Value))

	' Get the raw date in the format of Month Day[suffix], Year (4 = E)
	Dim rawDate = CStr(cells(4).Value)
	result.DateErrorMessage = ValidateDate(rawDate)
Next y
$vbLabelText   $csharpLabel

Muestra: DataValidation

Añadir una fórmula a una hoja de cálculo

Establezca la fórmula de Células con la propiedad Fórmula.

El siguiente código itera a través de cada estado y pone un porcentaje total en la columna C.

:path=/static-assets/excel/content-code-examples/tutorials/how-to-read-excel-file-csharp-13.cs
// Iterate through all rows with a value
for (var y = 2 ; y < i ; y++)
{
    // Get the C cell
    Cell cell = workSheet[$"C{y}"].First();

    // Set the formula for the Percentage of Total column
    cell.Formula = $"=B{y}/B{i}";
}
' Iterate through all rows with a value
Dim y = 2
Do While y < i
	' Get the C cell
	Dim cell As Cell = workSheet($"C{y}").First()

	' Set the formula for the Percentage of Total column
	cell.Formula = $"=B{y}/B{i}"
	y += 1
Loop
$vbLabelText   $csharpLabel

Muestra: AddFormulaeProcessor

Validar datos de hojas de cálculo

Utiliza IronXL para validar una hoja de datos. El ejemplo de DataValidation utiliza libphonenumber-csharp para validar números de teléfono y usa las API estándar de C# para validar direcciones de correo electrónico y fechas.

:path=/static-assets/excel/content-code-examples/tutorials/how-to-read-excel-file-csharp-8.cs
// Iterate through the rows
for (var i = 2; i <= 101; i++)
{
    var result = new PersonValidationResult { Row = i };
    results.Add(result);

    // Get all cells for the person
    var cells = worksheet[$"A{i}:E{i}"].ToList();

    // Validate the phone number (1 = B)
    var phoneNumber = cells[1].Value;
    result.PhoneNumberErrorMessage = ValidatePhoneNumber(phoneNumberUtil, (string)phoneNumber);

    // Validate the email address (3 = D)
    result.EmailErrorMessage = ValidateEmailAddress((string)cells[3].Value);

    // Get the raw date in the format of Month Day[suffix], Year (4 = E)
    var rawDate = (string)cells[4].Value;
    result.DateErrorMessage = ValidateDate(rawDate);
}
' Iterate through the rows
For i = 2 To 101
	Dim result = New PersonValidationResult With {.Row = i}
	results.Add(result)

	' Get all cells for the person
	Dim cells = worksheet($"A{i}:E{i}").ToList()

	' Validate the phone number (1 = B)
	Dim phoneNumber = cells(1).Value
	result.PhoneNumberErrorMessage = ValidatePhoneNumber(phoneNumberUtil, CStr(phoneNumber))

	' Validate the email address (3 = D)
	result.EmailErrorMessage = ValidateEmailAddress(CStr(cells(3).Value))

	' Get the raw date in the format of Month Day[suffix], Year (4 = E)
	Dim rawDate = CStr(cells(4).Value)
	result.DateErrorMessage = ValidateDate(rawDate)
Next i
$vbLabelText   $csharpLabel

El código anterior recorre cada fila de la hoja de cálculo y obtiene las celdas como una lista. Cada método validates comprueba el valor de una celda y devuelve un mensaje de error si el valor no es válido.

Este código crea una nueva hoja, especifica las cabeceras y emite los resultados del mensaje de error para que haya un registro de los datos no válidos.

:path=/static-assets/excel/content-code-examples/tutorials/how-to-read-excel-file-csharp-9.cs
var resultsSheet = workBook.CreateWorkSheet("Results");
resultsSheet["A1"].Value = "Row";
resultsSheet["B1"].Value = "Valid";
resultsSheet["C1"].Value = "Phone Error";
resultsSheet["D1"].Value = "Email Error";
resultsSheet["E1"].Value = "Date Error";
for (var i = 0; i < results.Count; i++)
{
    var result = results[i];
    resultsSheet[$"A{i + 2}"].Value = result.Row;
    resultsSheet[$"B{i + 2}"].Value = result.IsValid ? "Yes" : "No";
    resultsSheet[$"C{i + 2}"].Value = result.PhoneNumberErrorMessage;
    resultsSheet[$"D{i + 2}"].Value = result.EmailErrorMessage;
    resultsSheet[$"E{i + 2}"].Value = result.DateErrorMessage;
}
workBook.SaveAs(@"Spreadsheets\\PeopleValidated.xlsx");
Dim resultsSheet = workBook.CreateWorkSheet("Results")
resultsSheet("A1").Value = "Row"
resultsSheet("B1").Value = "Valid"
resultsSheet("C1").Value = "Phone Error"
resultsSheet("D1").Value = "Email Error"
resultsSheet("E1").Value = "Date Error"
For i = 0 To results.Count - 1
	Dim result = results(i)
	resultsSheet($"A{i + 2}").Value = result.Row
	resultsSheet($"B{i + 2}").Value = If(result.IsValid, "Yes", "No")
	resultsSheet($"C{i + 2}").Value = result.PhoneNumberErrorMessage
	resultsSheet($"D{i + 2}").Value = result.EmailErrorMessage
	resultsSheet($"E{i + 2}").Value = result.DateErrorMessage
Next i
workBook.SaveAs("Spreadsheets\\PeopleValidated.xlsx")
$vbLabelText   $csharpLabel

4. Exportación de datos mediante Entity Framework

Utilice IronXL para exportar datos a una base de datos o convertir una hoja de cálculo de Excel en una base de datos. El ejemplo ExcelToDB lee una hoja de cálculo con el PIB por país y luego exporta esos datos a un SQLite.

Utiliza EntityFramework para construir la base de datos y luego exportar los datos línea por línea.

Añade los paquetes NuGet de SQLite Entity Framework.

Ironxl Nuget related to 4. Exportación de datos mediante Entity Framework

EntityFramework te permite crear un objeto modelo que puede exportar datos a la base de datos.

:path=/static-assets/excel/content-code-examples/tutorials/how-to-read-excel-file-csharp-10.cs
public class Country
    {
        [Key]
        public Guid Key { get; set; }
        public string Name { get; set; }
        public decimal GDP { get; set; }
    }
Public Class Country
		<Key>
		Public Property Key() As Guid
		Public Property Name() As String
		Public Property GDP() As Decimal
End Class
$vbLabelText   $csharpLabel

Para usar una base de datos diferente, instala el paquete NuGet correspondiente y encuentra el equivalente de UseSqLite()

:path=/static-assets/excel/content-code-examples/tutorials/how-to-read-excel-file-csharp-11.cs
public class CountryContext : DbContext
    {
        public DbSet<Country> Countries { get; set; }
        public CountryContext()
        {
            //TODO: Make async
            Database.EnsureCreated();
        }
        /// <summary>
        /// Configure context to use Sqlite
        /// </summary>
        /// <param name="optionsBuilder"></param>
        protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder)
        {
            var connection = new SqliteConnection($"Data Source=Country.db");
            connection.Open();
            var command = connection.CreateCommand();
            //Create the database if it doesn't already exist
            command.CommandText = $"PRAGMA foreign_keys = ON;";
            command.ExecuteNonQuery();
            optionsBuilder.UseSqlite(connection);
            base.OnConfiguring(optionsBuilder);
        }
    }
Public Class CountryContext
	Inherits DbContext

		Public Property Countries() As DbSet(Of Country)
		Public Sub New()
			'TODO: Make async
			Database.EnsureCreated()
		End Sub
		''' <summary>
		''' Configure context to use Sqlite
		''' </summary>
		''' <param name="optionsBuilder"></param>
		Protected Overrides Sub OnConfiguring(ByVal optionsBuilder As DbContextOptionsBuilder)
			Dim connection = New SqliteConnection($"Data Source=Country.db")
			connection.Open()
			Dim command = connection.CreateCommand()
			'Create the database if it doesn't already exist
			command.CommandText = $"PRAGMA foreign_keys = ON;"
			command.ExecuteNonQuery()
			optionsBuilder.UseSqlite(connection)
			MyBase.OnConfiguring(optionsBuilder)
		End Sub
End Class
$vbLabelText   $csharpLabel

Cree un CountryContext, recorra el rango para crear cada registro y luego use SaveAsync para comprometer los datos en la base de datos

:path=/static-assets/excel/content-code-examples/tutorials/how-to-read-excel-file-csharp-12.cs
public async Task ProcessAsync()
{
    //Get the first worksheet
    var workbook = WorkBook.Load(@"Spreadsheets\\GDP.xlsx");
    var worksheet = workbook.GetWorkSheet("GDPByCountry");
    //Create the database connection
    using (var countryContext = new CountryContext())
    {
        //Iterate through all the cells
        for (var i = 2; i <= 213; i++)
        {
            //Get the range from A-B
            var range = worksheet[$"A{i}:B{i}"].ToList();
            //Create a Country entity to be saved to the database
            var country = new Country
            {
                Name = (string)range[0].Value,
                GDP = (decimal)(double)range[1].Value
            };
            //Add the entity
            await countryContext.Countries.AddAsync(country);
        }
        //Commit changes to the database
        await countryContext.SaveChangesAsync();
    }
}
Public Async Function ProcessAsync() As Task
	'Get the first worksheet
	Dim workbook = WorkBook.Load("Spreadsheets\\GDP.xlsx")
	Dim worksheet = workbook.GetWorkSheet("GDPByCountry")
	'Create the database connection
	Using countryContext As New CountryContext()
		'Iterate through all the cells
		For i = 2 To 213
			'Get the range from A-B
			Dim range = worksheet($"A{i}:B{i}").ToList()
			'Create a Country entity to be saved to the database
			Dim country As New Country With {
				.Name = CStr(range(0).Value),
				.GDP = CDec(CDbl(range(1).Value))
			}
			'Add the entity
			Await countryContext.Countries.AddAsync(country)
		Next i
		'Commit changes to the database
		Await countryContext.SaveChangesAsync()
	End Using
End Function
$vbLabelText   $csharpLabel

Muestra: ExcelToDB

5. Descarga de datos de una API a una hoja de cálculo

La siguiente llamada realiza una llamada REST con RestClient.Net. Descarga JSON y lo convierte en una "Lista" del tipo RestCountry. A continuación, es fácil iterar por cada país y guardar los datos de la API REST en una hoja de cálculo Excel.

:path=/static-assets/excel/content-code-examples/tutorials/how-to-read-excel-file-csharp-14.cs
var client = new Client(new Uri("https://restcountries.eu/rest/v2/"));
List<RestCountry> countries = await client.GetAsync<List<RestCountry>>();
Dim client As New Client(New Uri("https://restcountries.eu/rest/v2/"))
Dim countries As List(Of RestCountry) = Await client.GetAsync(Of List(Of RestCountry))()
$vbLabelText   $csharpLabel

Muestra: ApiToExcel

Este es el aspecto de los datos JSON de la API.

Country Data related to 5. Descarga de datos de una API a una hoja de cálculo

El siguiente código recorre los países y establece el Nombre, la Población, la Región, el CódigoNumérico y los 3 Idiomas principales en la hoja de cálculo.

:path=/static-assets/excel/content-code-examples/tutorials/how-to-read-excel-file-csharp-15.cs
for (var i = 2; i < countries.Count; i++)
{
    var country = countries[i];
    //Set the basic values
    workSheet[$"A{i}"].Value = country.name;
    workSheet[$"B{i}"].Value = country.population;
    workSheet[$"G{i}"].Value = country.region;
    workSheet[$"H{i}"].Value = country.numericCode;
    //Iterate through languages
    for (var x = 0; x < 3; x++)
    {
        if (x > (country.languages.Count - 1)) break;
        var language = country.languages[x];
        //Get the letter for the column
        var columnLetter = GetColumnLetter(4 + x);
        //Set the language name
        workSheet[$"{columnLetter}{i}"].Value = language.name;
    }
}
For i = 2 To countries.Count - 1
	Dim country = countries(i)
	'Set the basic values
	workSheet($"A{i}").Value = country.name
	workSheet($"B{i}").Value = country.population
	workSheet($"G{i}").Value = country.region
	workSheet($"H{i}").Value = country.numericCode
	'Iterate through languages
	For x = 0 To 2
		If x > (country.languages.Count - 1) Then
			Exit For
		End If
		Dim language = country.languages(x)
		'Get the letter for the column
		Dim columnLetter = GetColumnLetter(4 + x)
		'Set the language name
		workSheet($"{columnLetter}{i}").Value = language.name
	Next x
Next i
$vbLabelText   $csharpLabel

Referencia de objetos y recursos

También puede encontrar la [documentación de la clase IronXL](/csharp/excel/object-reference/api/" target="_blank) dentro de la Referencia de Objetos de gran valor.

Además, hay otros tutoriales que pueden arrojar luz sobre otros aspectos de IronXL.Excel, incluyendo Creación, Apertura, Escritura, Edición, Guardado y Exportación de archivos XLS, XLSX y CSV sin usar Excel Interop.

Resumen

IronXL.Excel es solo .NET biblioteca de software para la lectura de una amplia variedad de formatos de hoja de cálculo. No requiere que Microsoft Excel esté instalado y no depende de Interop.

Si encuentras la biblioteca .NET útil para modificar archivos de Excel, también podrías estar interesado en explorar la Google Sheets API Client Library para .NET que te permite modificar Google Sheets.


Acceso rápido a tutoriales

Brand Visual Studio related to Acceso rápido a tutoriales

Download this Tutorial as C# Source Code

The full free C# for Excel Source Code for this tutorial is available to download as a zipped Visual Studio 2017 project file.

Download

Explore this Tutorial on GitHub

The source code for this project is available in C# and VB.NET on GitHub.

Use this code as an easy way to get up and running in just a few minutes. The project is saved as a Microsoft Visual Studio 2017 project, but is compatible with any .NET IDE.

How to Read Excel File in C# on GitHub
Github Icon related to Acceso rápido a tutoriales
Documentation related to Acceso rápido a tutoriales

Ver la referencia de la API

Explore la Referencia de la API para IronXL, que describe los detalles de todas las características, espacios de nombres, clases, métodos, campos y enums de IronXL.

Ver la referencia de la API
Director de soluciones .NET trabajando con documentos Microsoft Excel IO
Jefe de equipo de desarrollo de software

Christian desarrolla software para la industria de la salud y lidera un equipo. Christian tiene años de experiencia integrando con sistemas de todo tipo. IronXL permite a Christian importar y manipular datos de diferentes fuentes para automatizar tareas repetitivas y validar datos de entrada de fuentes de terceros.