Shikha Rathi
Shikha Rathi

Reputation: 1

Combine last name and initial of first name in excel - format of the word is "last name, first name" in single cell

I want to create user Id using "Initials of first name.last name", the format of the word is "last name, first name" in single cell.

Column D - Smith, John

Result - J.Smith

I used = =PROPER(TRIM(LEFT(SUBSTITUTE(D3," ",REPT(" ",99)),99))&"."&RIGHT(D3,(LEN(D3)-FIND(", ",D3)-1)))

Please help. Thanks in advance.

Upvotes: 0

Views: 971

Answers (1)

user4039065
user4039065

Reputation:

Try,

=MID(D3, FIND(",", D3&",  ")+2, 1)&". "&LEFT(D3, FIND(",", D3&",")-1)

enter image description here

Upvotes: 3

Related Questions