Soul.XLS 1.1.2

dotnet add package Soul.XLS --version 1.1.2                
NuGet\Install-Package Soul.XLS -Version 1.1.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="Soul.XLS" Version="1.1.2" />                
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Soul.XLS --version 1.1.2                
#r "nuget: Soul.XLS, 1.1.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.
// Install Soul.XLS as a Cake Addin
#addin nuget:?package=Soul.XLS&version=1.1.2

// Install Soul.XLS as a Cake Tool
#tool nuget:?package=Soul.XLS&version=1.1.2                
public static void TestWriter()
{
    var columns = new ExcelColumnCollection("学生信息")
    {
        new ExcelColumn("学生信息")
        {
            Items = new []
            {
                new ExcelColumn("个人信息")
                {
                    Items = new []
                    {
                        new ExcelColumn("姓名"),
                        new ExcelColumn("生日", style =>
                        {
                            style.ColumnWidth = 14;
                            style.Alignment = HorizontalAlignment.Center;
                        }),
                    }
                },
                new ExcelColumn("家庭信息")
                {
                    Items = new []
                    {
                        new ExcelColumn("地址"),
                        new ExcelColumn("电话"),
                    }
                },
            }
        },
        new ExcelColumn("成绩")
        {
            Items = new []
            {
                new ExcelColumn("文综")
                {
                    Items = new []
                    {
                        new ExcelColumn("语文"),
                        new ExcelColumn("历史"),
                    }
                },
                new ExcelColumn("理综")
                {
                    Items = new []
                    {
                        new ExcelColumn("数学",style=>
                        {
                            style.Format = "0.00";
                        }),
                        new ExcelColumn("物理"),
                    }
                }
            }
        }
    };
    var table1 = new ExcelTable("学生信息", columns);
    table1.FreezePanes(4, 1);
    for (int i = 0; i < 100; i++)
    {
        var row = table1.NewRow();
        row["姓名"] = "花间岛";
        row["生日"] = DateTime.Now.ToString();
        row["地址"] = "浙江杭州";
        row["电话"] = "10086";
        row["语文"] = 100;
        row["历史"] = 50;
        row["数学"] = 99;
        row["物理"] = 97;
        table1.Rows.Add(row);
    }
    var table2 = new ExcelTable("消费信息", new ExcelColumnCollection("消费信息")
    {
        new ExcelColumn("商品",style=>
        {
            style.Alignment = HorizontalAlignment.Center;
        }),
        new ExcelColumn("价格"),
    });
    for (int i = 0; i < 100; i++)
    {
        var row = table2.NewRow();
        row["商品"] = "哇哈哈";
        row["价格"] = 15.2;
        table2.Rows.Add(row);
    }
    var workbook = new ExcelWorkbook();
    workbook.Tables.Add(table1);
    workbook.Tables.Add(table2);
    workbook.SaveToFile("D:\\ff.xlsx", ExcelFileType.Xlsx);
}

public static void TestReader()
{
    var workbook = new ExcelWorkbook();
    workbook.LoadFormFile("D:\\ff.xlsx");
    var sheet = workbook.GetSheet(0);
    var table = workbook.ExportTable(0, 1, 9);
    foreach (var item in table.Rows)
    {
        var a1 = item.GetValue<decimal?>("语文");
        var a2 = item.GetValue<decimal>("历史");
        var a3 = item.GetValue<decimal>("数学");
        var a4 = item.GetValue<DateTime>("生日");
    }
}

alternate text is missing from this package README image

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. 
.NET Core netcoreapp2.0 was computed.  netcoreapp2.1 was computed.  netcoreapp2.2 was computed.  netcoreapp3.0 was computed.  netcoreapp3.1 was computed. 
.NET Standard netstandard2.0 is compatible.  netstandard2.1 was computed. 
.NET Framework net461 was computed.  net462 was computed.  net463 was computed.  net47 was computed.  net471 was computed.  net472 was computed.  net48 was computed.  net481 was computed. 
MonoAndroid monoandroid was computed. 
MonoMac monomac was computed. 
MonoTouch monotouch was computed. 
Tizen tizen40 was computed.  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.
  • .NETStandard 2.0

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
1.1.2 132 9/11/2024
1.1.1 107 8/30/2024
1.1.0 120 8/21/2024
1.0.5.2 111 7/23/2024
1.0.5.1 96 7/23/2024
1.0.5 95 7/4/2024