Hi all,
I need to allow sorting in an unlocked table within a protected sheet. I have enabled filtering, but for some reason sorting is an issue. Every time I try and sort I'm prompted with "The cell or chart you're trying to change is on a protected sheet. To make a change, protect the sheet. You might be requested to enter a password." The code I use to protect the sheet is below. The allow filtering works, but I'm having an issue with the allow sorting. I would like to avoid this, but I could write code that unlocks the entire sheet if the topline of the taple (row 18) is selected. This would allow sorting then re-lock the sheet. Any suggestions would be greatly appreciated!
I need to allow sorting in an unlocked table within a protected sheet. I have enabled filtering, but for some reason sorting is an issue. Every time I try and sort I'm prompted with "The cell or chart you're trying to change is on a protected sheet. To make a change, protect the sheet. You might be requested to enter a password." The code I use to protect the sheet is below. The allow filtering works, but I'm having an issue with the allow sorting. I would like to avoid this, but I could write code that unlocks the entire sheet if the topline of the taple (row 18) is selected. This would allow sorting then re-lock the sheet. Any suggestions would be greatly appreciated!
HTML:
ws.Protect wsSettings.Range("Settings_Password"), AllowFiltering:=True, AllowSorting:=True