Hi, I need to filter a range based on the date in column A. I am using the below code for that, but it is not working 100%. In short, I want to filter either ascending or descending, and the complete row need to be moved in the correct order ( Col A-H )
Does anybody have an idea on how to improve the code?
Does anybody have an idea on how to improve the code?
VBA Code:
Sub Sort()
Range("A1").Select
Range(Selection, Selection.End(xlToRight)).Select
Range(Selection, Selection.End(xlDown)).Select
Selection.Sort key1:=Range("A1", Range("A1").End(xlDown)), _
order1:=xlAscending, Header:=xlNo
End Sub