Forum Discussion
Filter in a protected xlsx sheet.
- May 05, 2018
Hi,
Please try to enable the filter before you protect the worksheet.
And when you go to protect it, check the Filter check box to allow users to use it.

It works in Excel for Windows, and I think it will work on Mac as well.
Good luck
Hi,
Please try to enable the filter before you protect the worksheet.
And when you go to protect it, check the Filter check box to allow users to use it.

It works in Excel for Windows, and I think it will work on Mac as well.
Good luck
Hi,
I have the same issue but I understand how to unlock cells and choose for sorting and filtering before I protect the sheet. It still doesn't allow me to sort the data. I read that the cells must all be unlocked but is there a way to filter even when some of the cells are locked? I have formulas and am afraid those using it will accidently delete the formulas without protection.
- Haytham AmairahJul 30, 2019Silver Contributor
I just discover a fairly good solution for this.
- keep all cells in the locked state which is the default
- Enable the AutoFilter
- Before you enable the protection, go to Review >> Protect >> Allow Edit Ranges
- Add the range that you want as the below screenshot
- Press the Protect Sheet button in the same dialog
- In the Protect Sheet, deselect the first two options and select only: Sort and Use AutoFilter
- Hit OK
This will prevent the users from accidentally delete any cell's content by preventing them from even select the cells but they will still be allowed to use the Sort and Filter!
Hope that helps
- wlmexcelfunAug 02, 2019Copper Contributor
Thank you!!! This worked perfectly!
- Haytham AmairahJul 30, 2019Silver Contributor
The filter, sort, and delete are types of editing, so you can't restrict one without the other!
If you want to prevent the users from deleting the content, you will prevent them from sorting and filtering as well.