Mostafa_Mwafick
New Member
- Joined
- Aug 15, 2018
- Messages
- 1
Hi all
I ave used this code for auto filter↓,
Sub Autofilter_by_selection()
Range(ActiveCell.CurrentRegion.Address).AutoFilter Field:=ActiveCell.Column, Criteria1:=ActiveCell.Value
End Sub
it works in all sheets but the table format
it gave me error
"runtime error '1004' autofit method of range class failed and sub autofilter_by_selection()
I need help!
I ave used this code for auto filter↓,
Sub Autofilter_by_selection()
Range(ActiveCell.CurrentRegion.Address).AutoFilter Field:=ActiveCell.Column, Criteria1:=ActiveCell.Value
End Sub
it works in all sheets but the table format
it gave me error
"runtime error '1004' autofit method of range class failed and sub autofilter_by_selection()
I need help!