CommonNetFuncs.Csv 4.3.2

dotnet add package CommonNetFuncs.Csv --version 4.3.2
                    
NuGet\Install-Package CommonNetFuncs.Csv -Version 4.3.2
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="CommonNetFuncs.Csv" Version="4.3.2" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="CommonNetFuncs.Csv" Version="4.3.2" />
                    
Directory.Packages.props
<PackageReference Include="CommonNetFuncs.Csv" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add CommonNetFuncs.Csv --version 4.3.2
                    
#r "nuget: CommonNetFuncs.Csv, 4.3.2"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package CommonNetFuncs.Csv@4.3.2
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=CommonNetFuncs.Csv&version=4.3.2
                    
Install as a Cake Addin
#tool nuget:?package=CommonNetFuncs.Csv&version=4.3.2
                    
Install as a Cake Tool

CommonNetFuncs.Csv

License NuGet Version nuget

This project contains helper methods for reading and writing CSV files.

Contents


CsvExportHelpers

Helpers for exporting data to a CSV file.

CsvExportHelpers Usage Examples

<details> <summary><h3>Usage Examples</h3></summary>

ExportToCsv

Export data from an IEnumerable or DataTable

public class Person
{
  public string Name { get; set; }
  public int Age { get; set; }
}

Person[] testData = [ new() { Name = "Chris", Age = 32 }, new() { Name = "Nick", Age = 43 } ];
await using MemoryStream ms = new();
await testData.ExportToCsv(ms); // ms contains CSV data for testData

</details>


CsvReadHelpers

Helpers for ingesting data from CSV files.

CsvReadHelpers Usage Examples

<details> <summary><h3>Usage Examples</h3></summary>

ReadCsv

Read CSV data directly from a physical CSV file or stream containing its data into a List. CSV data should match the type of T.

public class Person
{
  public string Name { get; set; }
  public int Age { get; set; }
}

List<Person> csvPeople = CsvReadHelpers.ReadCsv(@"C:\Documents\People.csv"); // csvPeople contains list of values from People.csv
ReadCsvAsync

Asynchronously read CSV data directly from a physical CSV file or stream containing its data into a List. CSV data should match the type of T.

public class Person
{
  public string Name { get; set; }
  public int Age { get; set; }
}

List<Person> csvPeople = await CsvReadHelpers.ReadCsvAsync(@"C:\Documents\People.csv"); // csvPeople contains list of values from People.csv
ReadCsvAsyncEnumerable

Asynchronously read CSV data directly from a physical CSV file or stream containing its data into an IAsyncEnumerable. CSV data should match the type of T.

public class Person
{
  public string Name { get; set; }
  public int Age { get; set; }
}

List<Person> result = new();
await foreach (Person record in CsvReadHelpers.ReadCsvAsyncEnumerable<Person>(@"C:\Documents\People.csv"))
{
    result.Add(record);
}
// Result contains list of all records within People.csv
ReadCsvToDataTable

Read CSV data directly from a physical CSV file or stream containing its data into a DataTable. DataTable can be constructed with a definite or indefinite type

public class Person
{
  public string Name { get; set; }
  public int Age { get; set; }
}

using DataTable dataTable = CsvReadHelpers.ReadCsvToDataTable(@"C:\Documents\People.csv"); // Indeterminate type in People.csv, dataTable contains all records from People.csv with all values as strings

using DataTable dataTable = CsvReadHelpers.ReadCsvToDataTable(@"C:\Documents\People.csv", typeof(Person)); // Known type in People.csv, dataTable contains all records from People.csv with all values typed per Person class

</details>

Installation

Install via NuGet:

dotnet add package CommonNetFuncs.Csv

License

This project is licensed under the MIT License - see the LICENSE file for details.

Product Compatible and additional computed target framework versions.
.NET net5.0 was computed.  net5.0-windows was computed.  net6.0 was computed.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 was computed.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 was computed.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 was computed.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
.NET Core netcoreapp3.0 was computed.  netcoreapp3.1 was computed. 
.NET Standard netstandard2.1 is compatible. 
MonoAndroid monoandroid was computed. 
MonoMac monomac was computed. 
MonoTouch monotouch was computed. 
Tizen tizen60 was computed. 
Xamarin.iOS xamarinios was computed. 
Xamarin.Mac xamarinmac was computed. 
Xamarin.TVOS xamarintvos was computed. 
Xamarin.WatchOS xamarinwatchos was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (1)

Showing the top 1 NuGet packages that depend on CommonNetFuncs.Csv:

Package Downloads
CommonNetFuncs.Web.Ftp

Helpers for connecting to and working with FTP servers

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
4.3.2 48 8/14/2026
4.3.1 109 8/11/2026
4.3.0 139 8/3/2026
4.1.14 132 8/3/2026
4.1.12 135 7/31/2026
4.1.11 137 7/9/2026
4.1.0 137 6/5/2026
4.0.53 136 5/28/2026
4.0.43 123 5/14/2026
4.0.42 128 5/11/2026
4.0.40 345 5/10/2026
4.0.39 131 5/10/2026
4.0.37 134 5/9/2026
4.0.36 120 5/8/2026
4.0.31 148 4/21/2026
4.0.29 130 4/20/2026
4.0.28 120 4/19/2026
4.0.25 138 4/3/2026
Loading failed