先按要求录制宏再更改:
Sub Macro1()
For i = 1 To Range("A65535").End(xlUp).Row
Range("A" & i & ":E" & i).Sort Key1:=Range("A" & i), Order1:=xlAscending, Header:=xlGuess, _
OrderCustom:=1, MatchCase:=False, Orientation:=xlLeftToRight, SortMethod _
:=xlPinYin, DataOption1:=xlSortNormal
Next
End Sub