LR
Lokesh R
Syncfusion Team
May 7, 2010 06:52 AM UTC
Hi Nick,
Thank you very much for using Syncfusion products.
As you have reported in your post. The equivalent permission set in 8.2.0.18 for the ExcelSheetProtection.DefaultProtect constant available in 6.3.1.8 is
ExcelSheetProtection.LockedCells | ExcelSheetProtection.UnLockedCells. Below, I have also added the code snippet for the same, could you please try the code snippet and let us know if this helps you.
[C#] Code Snippet:
ExcelEngine engine = new ExcelEngine();
IApplication app = engine.Excel;
IWorkbook workBook = app.Workbooks.Create(2);
//Equivalent permission set in 8.2.0.18 for the Defaultprotect option available in 6.3.1.8
workBook.Worksheets[0].Protect("Syncfusion", ExcelSheetProtection.LockedCells | ExcelSheetProtection.UnLockedCells);
workBook.SaveAs("Sample.xls");
workBook.Close();
Please, let us know if you have any queries.
Thanks,
Lokesh.