Hi i have the below code to sort by multiple columns but for some reason it is not working. I do not get an error message but the code doesn't work. What am i missing?
Thanks for your help
Thanks for your help
Code:
With ActiveSheet.Sort
.SortFields.Clear
.SortFields.Add Key:=Range("D9:D700" _
), SortOn:=xlSortOnValues, Order:=xlAscending, DataOption:=xlSortNormal
.SortFields.Add Key:=Range("J9:j700" _
), SortOn:=xlSortOnValues, Order:=xlDescending, DataOption:=xlSortNormal
.SetRange Range("B9:N700")
.Header = xlYes
.MatchCase = False
.Orientation = xlTopToBottom
.SortMethod = xlPinYin
.Apply
End With