Hi Experts,
I have a table with headers. I locked the cells that contain headers (apart from all other cells I need to protect). I have some macros to allow the users to filter the data based on the selection in a dropdown list. The macros should first unprotect the worksheet and do whatever coded then unprotect back the worksheet BUT allowing the autofilter on the lockedcells (headers). I notice that when I manually protect the worksheet and manually select option to allow AutoFilter, the filter works on locked cells but it won't work when I apply by coding. I've googled and referred to all similar issues and the solutions always recommend the below code:-
ActiveSheet.Protect AllowFiltering:=True, Password:="abc1234##"
however, the above code doesn't work as how it works when selecting and protecting manually. Did I miss anythg? Appreciate some help as I've been trying this for hours already but still fail.
Thank you in advance.
DZ
I have a table with headers. I locked the cells that contain headers (apart from all other cells I need to protect). I have some macros to allow the users to filter the data based on the selection in a dropdown list. The macros should first unprotect the worksheet and do whatever coded then unprotect back the worksheet BUT allowing the autofilter on the lockedcells (headers). I notice that when I manually protect the worksheet and manually select option to allow AutoFilter, the filter works on locked cells but it won't work when I apply by coding. I've googled and referred to all similar issues and the solutions always recommend the below code:-
ActiveSheet.Protect AllowFiltering:=True, Password:="abc1234##"
however, the above code doesn't work as how it works when selecting and protecting manually. Did I miss anythg? Appreciate some help as I've been trying this for hours already but still fail.
Thank you in advance.
DZ