sorting a column
Give this function a try...
Public Function FormatName(ByVal InputName As String) As String
FormatName = Right(InputName, Len(InputName) - InStrRev(Trim(InputName),
" ")) & _
", " & Trim(Left(InputName, InStrRev(InputName, " ")))
End Function
"Alex" wrote:
I have a column with a last and a first names as follows
Employee Name
Thibodeau, Cheryl
Milan, Nick
Chian, Mary
Janzen, Eliane
....
I need to sort it by the first name, which is the second word after the coma.
How could I do this?
Thanks
|