Easy_Excel_Maker 1.0.0
dotnet add package Easy_Excel_Maker --version 1.0.0
NuGet\Install-Package Easy_Excel_Maker -Version 1.0.0
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="Easy_Excel_Maker" Version="1.0.0" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Easy_Excel_Maker --version 1.0.0
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: Easy_Excel_Maker, 1.0.0"
#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 Easy_Excel_Maker as a Cake Addin #addin nuget:?package=Easy_Excel_Maker&version=1.0.0 // Install Easy_Excel_Maker as a Cake Tool #tool nuget:?package=Easy_Excel_Maker&version=1.0.0
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
static void Main(string[] args) {
Program p = new Program();
p.dttoExcelSingle(@"d:\DemoSingleDaTatableToExcel.xls");
p.MergeManyDatatabletoSingleExcel(@"d:\ManyDatatableasSingleExcel.xls");
p.ArrayOfDtToMultiExcel(@"d:\Filename.xls");
}
public void dttoExcelSingle(string path)
{
DataTable dt = new DataTable();
dt.Clear();
dt.Columns.Add("Name");
dt.Columns.Add("Marks");
DataRow veera = dt.NewRow();
veera["Name"] = "Demo";
veera["Marks"] = "500";
dt.Rows.Add(veera);
EasyExcelMaker.EasyExcelMaker.ExportDataTableToExcel(dt, path);
}
public void MergeManyDatatabletoSingleExcel(string path)
{
DataTable[] dd = new DataTable[3];
dd[0] = new DataTable();
dd[1] = new DataTable();
dd[0].Clear();
dd[0].Columns.Add("Sno");
dd[0].Columns.Add("Name");
dd[0].Columns.Add("Phone");
dd[0].Columns.Add("address");
DataRow dr1 = dd[0].NewRow();
dr1["Sno"] = 1;
dr1["Name"] = "Sample";
dr1["Phone"] = "1245645690";
dr1["address"] = "Pondicherry";
dd[0].Rows.Add(dr1);
dd[1].Clear();
dd[1].Columns.Add("Sno");
dd[1].Columns.Add("Name");
dd[1].Columns.Add("Phone");
dd[1].Columns.Add("address");
DataRow dr2 = dd[1].NewRow();
dr2["Sno"] = 100;
dr2["Name"] = "Sample";
dr2["Phone"] = "9876543210";
dr2["address"] = "Pondicherry";
dd[1].Rows.Add(dr2);
EasyExcelMaker.EasyExcelMaker.MergingMultiDataTableAs_singleExcelSheet(dd, path, false); //true means with column header of datatables , false means merge all datatables rows with first datatable column header
}
public void ArrayOfDtToMultiExcel(string path)
{
DataTable[] dd = new DataTable[3];
dd[0] = new DataTable();
dd[1] = new DataTable();
dd[0].Clear();
dd[0].Columns.Add("Sno");
dd[0].Columns.Add("Name");
dd[0].Columns.Add("Phone");
dd[0].Columns.Add("address");
DataRow dr1 = dd[0].NewRow();
dr1["Sno"] = 1;
dr1["Name"] = "Sample";
dr1["Phone"] = "1245645690";
dr1["address"] = "Pondicherry";
dd[0].Rows.Add(dr1);
dd[1].Clear();
dd[1].Columns.Add("Sno");
dd[1].Columns.Add("Name");
dd[1].Columns.Add("Phone");
dd[1].Columns.Add("address");
DataRow dr2 = dd[1].NewRow();
dr2["Sno"] = 100;
dr2["Name"] = "Sample";
dr2["Phone"] = "9876543210";
dr2["address"] = "Pondicherry";
dd[1].Rows.Add(dr2);
EasyExcelMaker.EasyExcelMaker.MultiDataTableAs_MultiExcelFile(dd, path);
}
DataTable dd = new DataTable();
DataColumn dc = new DataColumn("Sno", Type.GetType("System.String"));
dd.Columns.Add("Sno");
dd.Columns.Add("Name");
dd.Columns.Add("Phone");
dd.Columns.Add("address");
DataRow dr1 = dd.NewRow();
dr1["Sno"] = 01;
dr1["Name"] = "Sample";
dr1["Phone"] = "1245645690";
dr1["address"] = "Pondicherry";
dd.Rows.Add(dr1);
StringBuilder sb = new StringBuilder();
sb = EasyExcelMaker.EasyExcelMaker.For_AspNetDtToExcel(dd);
string text = sb.ToString();
Response.Clear();
Response.ClearHeaders();
Response.AppendHeader("Content-Length", text.Length.ToString());
Response.ContentType = "text/plain";
Response.AppendHeader("Content-Disposition", "attachment;filename=\"output.xls\"");
Response.Write(text);
Response.End();
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET Framework | net20 is compatible. net30 is compatible. net35 is compatible. net40 is compatible. net403 was computed. net45 is compatible. net451 was computed. net452 was computed. net46 is compatible. net461 was computed. net462 was computed. net463 was computed. net47 was computed. net471 was computed. net472 was computed. net48 was computed. net481 was computed. |
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
This package has no dependencies.
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.0.0 | 707 | 8/5/2019 |
EasyExcelMaker