How to separate fname and fname in cell in excel

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Can soneone help me to wright a formula that will separate lname and fname in cell "B" to Cell"A "=lname and cell"B"=fname. Thy are separate by comma and space in cell "B" in excel 2000.
My e-mail address is (e-mail address removed)
 
Sub AABA()
Set cell = ActiveCell
If InStr(cell, ",") Then
iloc = InStr(cell, ",")
cell.Offset(0, -1).Value = Left(cell.Value, iloc - 1)
cell.Value = Right(cell.Value, Len(cell.Value) - (iloc + 1))
End If

End Sub

--
Regards,
Tom Ogilvy



Excel Problem said:
Can soneone help me to wright a formula that will separate lname and
fname in cell "B" to Cell"A "=lname and cell"B"=fname. Thy are separate by
comma and space in cell "B" in excel 2000.
 
data>text to columns is probably the easiest
or
a macro

--
Don Guillett
SalesAid Software
(e-mail address removed)
Excel Problem said:
Can soneone help me to wright a formula that will separate lname and
fname in cell "B" to Cell"A "=lname and cell"B"=fname. Thy are separate by
comma and space in cell "B" in excel 2000.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top