We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Deleting and adding tabs

Thread ID:





69555 Nov 1,2007 01:47 PM UTC Nov 5,2007 08:06 PM UTC ASP.NET Web Forms (Classic) 1
Tags: XlsIO
Craig Bart
Asked On November 1, 2007 01:47 PM UTC

Is there a way to prevent users from deleting and adding new worksheets to a workbook. I have a file that is generated using asp.net. This file has 3 tabs all of which are needed on upload. I have had problems with users removing tabs which cause there template to fail on upload. Thanks.

Nandakumar R [Syncfusion]
Replied On November 5, 2007 08:06 PM UTC


The Protect() method can be used to disable creating and deleting worksheets to a workbook.

Can you try the below code and let me know if this helps?

//Protect the Workbook from inserting and deleting the Worksheets.
workbook.Protect(false, true);



This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon