On this page you will learn from code samples for programming in C#. ByteScout Spreadsheet SDK helps with hidden rows and columns in C#. ByteScout Spreadsheet SDK is the SDK to create, read, modify and calculate spreadsheets. Formula calculations are supported, import and export to and from JSON, CSV, XML, databases, arrays.
The SDK samples like this one below explain how to quickly make your application do hidden rows and columns in C# with the help of ByteScout Spreadsheet SDK. In order to implement this functionality, you should copy and paste code below into your app using code editor. Then compile and run your application. Enjoy writing a code with ready-to-use sample C# codes to add hidden rows and columns functions using ByteScout Spreadsheet SDK in C#.
Free trial version of ByteScout Spreadsheet SDK is available on our website. Get it to try other samples for C#.
On-demand (REST Web API) version:
Web API (on-demand version)
On-premise offline SDK for Windows:
60 Day Free Trial (on-premise)
using System.Diagnostics; using System.IO; using Bytescout.Spreadsheet; namespace HiddenRowsAndColumns { class Program { static void Main(string[] args) { // Open spreadsheet from file Spreadsheet document = new Spreadsheet(); document.LoadFromFile("example.xls"); // Get first worksheet Worksheet worksheet = document.Workbook.Worksheets[0]; //Hide first three columns worksheet.Columns[0].Hidden = true; worksheet.Columns[1].Hidden = true; worksheet.Columns[2].Hidden = true; //Hide first three rows worksheet.Rows[0].Hidden = true; worksheet.Rows[1].Hidden = true; worksheet.Rows[2].Hidden = true; // Delete output file if exists if (File.Exists("changed.xls")) { File.Delete("changed.xls"); } // Save document document.SaveAs("changed.xls"); // Close spreadsheet document.Close(); // Open generated XLS document in default program Process.Start("changed.xls"); } } }
60 Day Free Trial or Visit ByteScout Spreadsheet SDK Home Page
Explore ByteScout Spreadsheet SDK Documentation
Explore Samples
Sign Up for ByteScout Spreadsheet SDK Online Training
Get Your API Key
Explore Web API Docs
Explore Web API Samples
60 Day Free Trial or Visit ByteScout Spreadsheet SDK Home Page
Explore ByteScout Spreadsheet SDK Documentation
Explore Samples
Sign Up for ByteScout Spreadsheet SDK Online Training
Get Your API Key
Explore Web API Docs
Explore Web API Samples
also available as: