I have a rather complicated (for me) excel file that I need to protect, but also need to enable filtering and grouping.
I am not at all competent with VBA and all I have discovered so far has been gleaned from the 'net. I have had help from various sources trying to sort this out, but nothing stays fixed.
I am using the following code;
It all works wonderfully until I close the file and try to re-open it. The grouping function remains, but the filtering stops working.![]()
Please Login or Register to view this content.
When I'm protecting the sheet, I make sure I tick 'Sort' and 'Use AutoFilter'.
But, everytime I re-open the file, Autofiltering is disabled. When I check in VBA, in the properties column I noticed that that EnableAutoFilter shows 'False'. I change this to 'True' and it works fine again.... until I shut it down and try to re-open it - and it's showing 'False' again.
I've attached the file to this post - the password to unprotect the sheet is 'mgs' and only the first two tabs require grouping and filtering.
Thanks in advance.
Muz
Bookmarks