Protect individual worksheets from deletion

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Using ThisWorkbook.Protect() protects the workbook structure from changing so
that no Worksheets can be added or deleted. I would like to protect certain
Worksheets from being deleted but not others. That is, I create some
Worksheets dynamically that I want users to be able to delete if necessary.
However, the five basic Worksheets need to be protected from deletion.

Is this possbile? If so, how.

Thanks,
John
 
Maybe you could give the users a dedicated macro that only delete the worksheets
that you want???
 
John,
A bit drastic, but might work for you...

In the Workbook_BeforeSave event, check for the existence of the five
sheets. It they are not all there then close the workbook without saving...

Cancel = True
This Workbook.Close SaveChanges:=False
--
Jim Cone
San Francisco, USA
http://www.realezsites.com/bus/primitivesoftware


"ejm3" <[email protected]>
wrote in message
Using ThisWorkbook.Protect() protects the workbook structure from changing so
that no Worksheets can be added or deleted. I would like to protect certain
Worksheets from being deleted but not others. That is, I create some
Worksheets dynamically that I want users to be able to delete if necessary.
However, the five basic Worksheets need to be protected from deletion.

Is this possbile? If so, how.

Thanks,
John
 
Hi ,

How is everything going? Please feel free to let me know if you need any
assistance.

Sincerely,

Wei Lu
Microsoft Online Community Support

==================================================

When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.

==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Back
Top