I have the code below for a search box on my worksheet that filters as a type. Is there something simple that I could add so that the search box contents are deleted automatically after I hit enter to search? I don't want to have to manually clear the contents each time.
Thanks.
Private Sub TextBox1_Change()
Application.ScreenUpdating = False
ActiveSheet.ListObjects("Antibodies").Range.AutoFilter Field:=1, Criteria1:="*" & [B2] & "*", Operator:=xlFilterValues
Application.ScreenUpdating = True
End Sub
Thanks.
Private Sub TextBox1_Change()
Application.ScreenUpdating = False
ActiveSheet.ListObjects("Antibodies").Range.AutoFilter Field:=1, Criteria1:="*" & [B2] & "*", Operator:=xlFilterValues
Application.ScreenUpdating = True
End Sub