C# Workbook Encryption (Password Protected) SpreadsheetGear API Sample
Excel-Compatible Samples for .NET
Description
SpreadsheetGear supports reading and writing Excel-compatible password-protected and encrypted workbooks with "Agile Encryption" used by Excel 2013 and later, including default SHA-512 encryption for workbooks. To save a workbook file with SpreadsheetGear that uses this password protection and encryption, simply call the overload of the
SpreadsheetGear.IWorkbook.SaveAs(...) method that accepts a password as the 3rd parameter, as demonstrated in this sample: