Re: $$Excel-Macros$$ define sort range

2013-08-22 Thread Peter Konijn
Thank a lot Your code works fine Kind regards Peter 2013/8/22 De Premor > try this code > > Sub sort() > Dim Str() As String > Str = Split([G4], ":") > With ActiveSheet.sort > .SortFields.Add Key:=Range(Str(0)) > .SetRange Range([G4]) > .Apply > End W

Re: $$Excel-Macros$$ define sort range

2013-08-22 Thread De Premor
try this code Sub sort() Dim Str() As String Str = Split([G4], ":") With ActiveSheet.sort .SortFields.Add Key:=Range(Str(0)) .SetRange Range([G4]) .Apply End With End Sub Pada 22/08/2013 18:39, Pekon menulis: Dear experts I hope that you can help me. I