Every ByteScout tool includes simple example C# source codes that you can get here or in the folder with installed ByteScout product. ByteScout Barcode Suite is the set that includes three different SDK products to generate barcodes, read barcodes and read and write spreadsheets: Barcode SDK, Barcode Reader SDK and Spreadsheet SDK. It can be applied to read xml spreadsheet (spreadsheetml format) with spreadsheet sdk using C#.
The following code snippet for ByteScout Barcode Suite works best when you need to quickly read xml spreadsheet (spreadsheetml format) with spreadsheet sdk in your C# application. Just copy and paste the code into your C# application’s code and follow the instructions. Use of ByteScout Barcode Suite in C# is also described in the documentation included along with the product.
The trial version of ByteScout Barcode Suite can be downloaded for free from our website. It also includes source code samples for C# and other programming languages.
On-demand (REST Web API) version:
Web API (on-demand version)
On-premise offline SDK for Windows:
60 Day Free Trial (on-premise)
using Bytescout.Spreadsheet; using System; namespace ReadSpreadsheetMLFormat { class Program { static void Main(string[] args) { try { //Convert SpreadhseetML (xml spreadsheet) to XLSX format using (var spreadsheet = new Spreadsheet()) { spreadsheet.RegistrationName = "demo"; spreadsheet.RegistrationKey = "demo"; // Load input file spreadsheet.LoadFromFile("sample.xml"); // Generate XLSX format spreadsheet.SaveAsXLSX("sample.xlsx"); } // Read spreadsheet and display data to console using (var spreadsheet = new Spreadsheet()) { spreadsheet.RegistrationName = "demo"; spreadsheet.RegistrationKey = "demo"; // Load input file spreadsheet.LoadFromFile("sample.xlsx"); //Reference Worksheet Worksheet worksheet = spreadsheet.Worksheets[0]; Console.WriteLine("====================================================="); Console.WriteLine("================ Spreadsheet data ==================="); Console.WriteLine("====================================================="); // Read and output cells to console. for (int row = worksheet.UsedRangeRowMin; row <= worksheet.UsedRangeRowMax; row++) { for (int column = worksheet.UsedRangeColumnMin; column <= worksheet.UsedRangeColumnMax; column++) { Console.Write("{0}\t", worksheet.Cell(row, column).ValueAsString); } Console.WriteLine(); } } } catch (Exception ex) { Console.WriteLine(ex.Message); } Console.WriteLine("Press any key to exit..."); Console.ReadLine(); } } }
60 Day Free Trial or Visit ByteScout Barcode Suite Home Page
Explore ByteScout Barcode Suite Documentation
Explore Samples
Sign Up for ByteScout Barcode Suite Online Training
Get Your API Key
Explore Web API Docs
Explore Web API Samples
60 Day Free Trial or Visit ByteScout Barcode Suite Home Page
Explore ByteScout Barcode Suite Documentation
Explore Samples
Sign Up for ByteScout Barcode Suite Online Training
Get Your API Key
Explore Web API Docs
Explore Web API Samples
also available as: