mamady
Board Regular
- Joined
- Sep 23, 2011
- Messages
- 238
- Office Version
- 365
- Platform
- Windows
Hi All,
I have the following code to clear out filters of a selected range, which works fine after assigning it to a button. However, if the button is clicked again I get a debug error. How can I disable that?
Thank you in advance
I have the following code to clear out filters of a selected range, which works fine after assigning it to a button. However, if the button is clicked again I get a debug error. How can I disable that?
VBA Code:
Sub ClearFilter()
' ClearFilter Macro
Application.ScreenUpdating = False
Rows("2:2").Select
ActiveSheet.ShowAllData
Range("A1").Select
Application.ScreenUpdating = True
End Sub
Thank you in advance
Last edited by a moderator: