"Cannot complete this action"

Excel "Cannot complete this action" When Deleting Rows in Protected Sheets

That error means Excel is blocking a delete on a locked or protected sheet. Unprotect the sheet, or uncheck the protect options for delete. Here's the fastest path to fix it.

You right-click a row header, hit Delete, and Excel throws "Cannot complete this action" at you. No other detail. No code. Just that useless little dialog box. If this is happening on a worksheet someone shared with you, or one you built months ago and locked down, the cause is almost always sheet protection. Excel is doing its job — it's refusing to let you change the structure of a sheet that's marked protected.

This shows up constantly in shared workbooks. Finance sends out a budget template, someone locks the sheet so nobody edits the formulas, and then returns come Monday morning because the person entering data can't insert or delete rows. Or you inherited a workbook from a coworker who quit and never told you the password.

Work through these in order. Stop as soon as the error goes away.

Fix #1: Unprotect the sheet (30 seconds)

This is the fix 9 times out of 10. If you have the password, you're done in under a minute.

  1. Click the Review tab at the top of Excel.
  2. Look for the Unprotect Sheet button. It sits in the Changes group on the right side of the ribbon.

If the button says Unprotect Sheet and it's clickable, the sheet is protected. Click it. If a password dialog appears, type the password and click OK. After it disappears, you should see the button text change to Protect Sheet. That confirms protection is off.

Now try deleting the row again. It should work immediately.

If the button is greyed out

That means one of two things. Either the sheet isn't protected (so the cause is something else — skip to Fix #3), or the workbook itself is protected at the structure level. Structure protection blocks adding, deleting, or renaming entire sheets, but it doesn't normally block row deletes. If you see Unprotect Workbook in the same group and it's clickable, the workbook is locked. Click it and enter the password.

If you don't have the password

Ask the person who sent you the file. That sounds snarky but it's genuinely the fastest route. If they're gone or unavailable, jump to Fix #2.

Fix #2: Allow deletes without removing protection (5 minutes)

Sometimes you can't unprotect the sheet because the protection is doing real work — locked formulas, data validation, formatting that other people keep breaking. You want protection to stay, but you need row and column deletion to be permitted.

Excel lets you do that. Here's how.

  1. Go to the Review tab and click Unprotect Sheet. Enter the password if prompted.
  2. Back on the Review tab, click Protect Sheet. A dialog opens with a list of checkboxes.
  3. At the top, there's a field labeled Allow all users of this worksheet to:. Scroll through the list.
  4. Find Delete rows and Delete columns. Tick both. Also tick Insert rows and Insert columns if you want the full set.
  5. Re-enter the password at the bottom and click OK.

After you click OK, the sheet is protected again, but those specific actions are now allowed. Test it: right-click a row header and select Delete. The error should be gone.

Watch out: if the cells inside the range you're deleting are locked, Excel may still refuse. Protection works at two levels — the sheet, and the individual cell's Locked property. If a locked cell sits inside a row you're trying to delete, Excel blocks the delete even with the box ticked. You'll need to unlock those cells first. Right-click them, choose Format Cells, go to the Protection tab, and untick Locked.

Fix #3: When it's not protection at all (15+ minutes)

If the sheet isn't protected and you still get the error, the problem is buried somewhere else. Work through these in order — they're listed roughly by how often they cause the problem.

Shared workbook mode

Shared workbooks (the old co-authoring feature, not the modern cloud co-authoring) are notorious for this. Go to ReviewShare Workbook. If the Allow changes by more than one user box is ticked, that's your culprit. Shared workbooks lock down structural changes in a lot of cases.

Untick the box, click OK, and save. You'll get a warning that the change history will be erased. If you don't care about history, accept it. Try the delete again.

Honestly, if you're still using shared workbooks in 2024, stop. Move the file to OneDrive or SharePoint and use real co-authoring. The old shared workbook mode has been half-broken for a decade.

Protected View or Read-Only mode

If you downloaded the file from email or the web, Excel may have opened it in Protected View. Look at the yellow bar at the top of the window. If it says PROTECTED VIEW, click Enable Editing. If it says READ-ONLY, click Edit Anyway.

You can also spot this in the title bar — a [Read-Only] tag appears after the filename. That alone will cause the "Cannot complete this action" error on any structural edit.

Merged cells inside the range

Merged cells fight with row deletion. If a merged cell spans across the row you're trying to delete, or worse, spans multiple rows, Excel gets confused. The fix is to hunt down the merged cells and unmerge them.

  1. Press Ctrl+H to open Find & Replace.
  2. Click Options to expand it.
  3. Click FormatAlignment tab → tick Merge cells → OK.
  4. Leave the Find what field empty and click Find All.

Excel highlights every merged cell in the sheet. Select them all (Ctrl+A in the results list), then go to HomeMerge & Center and click it to unmerge. Then retry your row delete.

Corrupted workbook

If nothing above worked, the file itself may be damaged. The test is simple: create a brand-new blank workbook and try deleting a row. If that works fine, the issue is specific to your file.

Try this recovery path:

  1. Open the problem file.
  2. Click FileSave As.
  3. Change the file type to Excel Binary Workbook (.xlsb) and save.
  4. Close the file, then reopen the .xlsb version.

The .xlsb format rewrites the file structure on disk and fixes a surprising number of corruption issues. If it works, save it back as .xlsx when you're done.

If that doesn't help, run FileOpen → browse to the file → click the arrow next to Open → Open and Repair. Choose Repair first; if that fails, try Extract Data.

Quick reference

SymptomLikely causeFix
Unprotect Sheet button is activeSheet protectionFix #1
Need to keep protection onSheet protection with locked cellsFix #2
Title bar shows [Read-Only]Read-only modeSave as new file
Yellow PROTECTED VIEW barTrusted location / downloadEnable Editing
Share Workbook is enabledLegacy shared modeTurn it off
Nothing else worksFile corruption.xlsb save or Open and Repair

Rule of thumb: if the sheet is protected and you have the password, Fix #1 takes half a minute. If you don't have the password, Fix #2 lets you keep the protection and open up the specific delete actions. Only go down the Fix #3 rabbit hole when neither applies — those issues are real but much less common than plain old sheet protection.

Related Errors in Software – Microsoft Office
Excel crashes on macro-enabled files? Fix the top 3 causes Excel crashes copying/pasting charts with linked data – fix Outlook Stuck on 'Loading profile...' After Windows Update? Fix It Excel hangs when inserting SVG icons — the real fix

Was this solution helpful?

EP
Erropedia Team
Tech Support Editors
The Erropedia editorial team researches and documents real-world tech errors from across Windows, Linux, macOS, networking, databases, cloud platforms, and more. Every solution is reviewed for accuracy and updated as software and systems evolve.