Import HTML file in .NET, Java and other programming languages
EasyXLS™ library allows you to import HTML files. The following actions are performed when the HTML is loaded:
- Import text data from HTML files - Import HTML tables - Import HTML formatting similarly as Excel cell formatting - Import images from HTML file - Import hyperlinks from HTML file
EasyXLS can be successfully used inclusively to import large HTML files having big volume of data with fast importing time.
// Create an instance of the class that imports HTML files
ExcelDocument workbook = new ExcelDocument();
// Import HTML file
workbook.easy_LoadHTMLFile("C:\\Samples\\file.html");
' Create an instance of the class that imports HTML filesDim workbook As New ExcelDocument
' Import HTML file
workbook.easy_LoadHTMLFile("C:\Samples\file.html")
C++// Create an instance of the class that imports HTML files
EasyXLS::IExcelDocumentPtr workbook;
hr = CoCreateInstance(__uuidof(EasyXLS::ExcelDocument),
NULL,
CLSCTX_ALL,
__uuidof(EasyXLS::IExcelDocument),
(void**) &workbook) ;
// Import HTML file
workbook->easy_LoadHTMLFile_2("C:\\Samples\\file.html");
Click here to see Continuous Code ListingC++.NET// Create an instance of the class that imports HTML files
ExcelDocument ^workbook = gcnew ExcelDocument();
// Import HTML file
workbook->easy_LoadHTMLFile("C:\\Samples\\file.html");
Click here to see Continuous Code Listing
// Create an instance of the class that imports HTML files
ExcelDocument workbook = new ExcelDocument();
// Import HTML file
workbook.easy_LoadHTMLFile("C:\\Samples\\file.html");
.NET:// Create an instance of the class that imports HTML files
$workbook = new COM("EasyXLS.ExcelDocument");
// Import HTML file
$workbook->easy_LoadHTMLFile_2("C:\Samples\file.html");
Click here to see Continuous Code ListingJava:// Create an instance of the class that imports HTML files
$workbook = new java("EasyXLS.ExcelDocument");
// Import HTML file
$workbook->easy_LoadHTMLFile("C:\Samples\file.html");
Click here to see Continuous Code Listing
' Create an instance of the class that imports HTML filesset workbook = Server.CreateObject("EasyXLS.ExcelDocument")
' Import HTML file
workbook.easy_LoadHTMLFile_2("C:\Samples\file.html")
' Create an instance of the class that imports HTML filesSet workbook = CreateObject("EasyXLS.ExcelDocument")
' Import HTML file
workbook.easy_LoadHTMLFile_2("C:\Samples\file.html")
' Create an instance of the class that imports HTML filesset workbook = CreateObject("EasyXLS.ExcelDocument")
' Import HTML file
workbook.easy_LoadHTMLFile_2("C:\Samples\file.html")
<!-- Create an instance of the class that imports HTML files --><cfobject type="java"class="EasyXLS.ExcelDocument"name="workbook"action="CREATE"><!-- Import HTML file --><cfset ret = workbook.easy_LoadHTMLFile("C:\Samples\file.html")>
.NET:# Create an instance of the class used to import/export Excel files
workbook = ExcelDocument()
# Import HTML file
workbook.easy_LoadHTMLFile("C:\\Samples\\file.html")
Click here to see Continuous Code ListingJava:# Create an instance of the class used to import/export Excel files
workbook = gateway.jvm.ExcelDocument()
# Import HTML file
workbook.easy_LoadHTMLFile("C:\\Samples\\file.html")
Click here to see Continuous Code Listing
Import HTML file with encoding
EasyXLS allows you to import HTML files with specific encoding using System.IO.StreamReader class in .NET and java.io.InputStreamReader class in Java with ExcelDocument.easy_LoadHTMLFile method.
Getting started with EasyXLS Excel library
To download the trial version of EasyXLS Excel Library, press the below button:
If you already own a license key, you may login and download EasyXLS from your account.