inserting rows on protected worksheet

MikeL

Active Member
Joined
Mar 17, 2002
Messages
488
Office Version
  1. 365
Platform
  1. Windows
Am new to board and was wondering if anyone has suggestions for how to insert rows onto a protected worksheet. I designed an Excel template but protected the worksheet (not the workbook) to preserve the file integrity. Some end users need to insert more rows into the spreadsheet. This option is ghosted. Any ideas? Also, am using Excel 2000.
Thanks in advance,
MikeL
 

Excel Facts

Remove leading & trailing spaces
Save as CSV to remove all leading and trailing spaces. It is faster than using TRIM().
Hi Mike


Excel XP has a lot more flexibility in this are but For 2000 or less you will need a macro:

Sub InsertaRow()
On Error GoTo ProtectAgain
ActiveSheet.Unprotect password:="secret"
ActiveCell.EntireRow.Insert
ProtectAgain:
ActiveSheet.Protect password:="secret"
End Sub

Push Alt+F11, go to Insert>Module and paste in the code. Push Alt+Q then Alt+F8, select the macro name and click "options" to assign a shortcut key.
 
Upvote 0

Forum statistics

Threads
1,214,400
Messages
6,119,289
Members
448,885
Latest member
LokiSonic

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top