web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Last name's initial le...
Power Apps
Unanswered

Last name's initial letter is sometimes blank

(0) ShareShare
ReportReport
Posted on by 107

I want to get the first and last name initials of the user.

I used DisplayName: User().FullName for _currUser.DisplayName, and the code below to get the initials but for some cases (3 names or more) this won't work.

 

Concatenate(Left(_currUser.DisplayName, 1), Left(Right(_currUser.DisplayName, Find(" ", _currUser.DisplayName)), 1))

 

 I know there is  MyProfileV2() but I wish using that will be my last option.

Categories:
I have the same question (0)
  • Rajkumar_M Profile Picture
    3,741 Super User 2025 Season 2 on at

    Hi

     

    Try this

     

    Concatenate(
    Left(
    Trim(_currUser.DisplayName),
    1),
    If(
    Len(
    Trim(
    Right(
    _currUser.DisplayName,
    Len(_currUser.DisplayName) - Find(" ", Trim(_currUser.DisplayName))
    ))
    ) > 0,
    Left(Trim(
    Right(
    _currUser.DisplayName,
    Len(_currUser.DisplayName) - Find(" ", Trim(_currUser.DisplayName))
    )),
    1
    ),
    ""
    ))

     

    Thanks!

     

    If my response has been helpful in resolving your issue, I kindly request that you consider clicking "Accept as solution" and "giving it a thumbs up" as a token of appreciation. 

  • rzainm Profile Picture
    107 on at

    Hi @Rajkumar_404 

     

    thanks for the response. I tried using your code but it works for people having one first name. If user has 2 or more first names eg. Angel Mae Smith, etc. it will get the initials for Angel Mae.

  • Rajkumar_M Profile Picture
    3,741 Super User 2025 Season 2 on at

    Try this

     

    Concatenate(
    Left( User().FullName & " " , 1),
    " ",
    Mid(
    User().FullName & " ",
    Find(" ", User().FullName & " " ) + 1,
    1
    ),
    " ",
    Right(
    User().FullName & " " ,
    Len(User().FullName & " " ) - Find(" ",User().FullName & " " , Find(" ",User().FullName & " " ) + 1)
    )
    )

     

    Thanks! 

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 711 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 319 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard