View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.misc
Gord Dibben Gord Dibben is offline
external usenet poster
 
Posts: 22,906
Default Delete Rows in a protected worksheet

Kathy

You can delete rows only if the entire row is unlocked before protecting the
sheet.

How will users select which rows to delete?

You could write code that would unprotect, insert rows at user's pre-defined
selection then re-protect the sheet.

Add a button for user to hit after selecting where to insert the rows.

Sub insertrows()
ActiveSheet.Unprotect Password:="justme"
Selection.EntireRow.Delete
ActiveSheet.Protect Password:="justme"
End Sub

Note: when protecting the sheet you must allow users to select locked cells.


Gord Dibben MS Excel MVP

On Tue, 10 Jun 2008 11:07:05 -0700, Kathy Connelly
wrote:

I need to be able to delete rows in a protected worksheet.

When I protect the worksheet it gives me the option to be able to allow a
user to delete rows - I check that box. However, it will not allow me to
delete the rows after I protect it.

Can you tell me what I need to do?