Text to columns
On Thu, 28 Feb 2008 10:40:00 -0800, Bill
wrote:
I have data in the form of 2.00 x 3.00 x 5.00 CRS. I want to seperate the
CRS into a new column. Sometimes there is only 2 values before crs such as
2.00 x 4.00 CRS, but what I want to seperate is always last and always has a
space before it. Can anyone help?
Thanks
Bill
This UDF will return the last word in a string:
====================
Function LastWord(str As String) As String
LastWord = Split(str)(UBound(Split(str)))
End Function
=======================
If there might be trailing spaces, then:
==========================
Function LastWord(str As String) As String
LastWord = Split(Trim(str))(UBound(Split(Trim(str))))
End Function
==========================
--ron
|