cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
LisaC
Level: Powered On

Splitting a sharepoint list item in power app label

I'm connecting to a sharepoint list.  One list item is DisplayName and it looks like this "Carslon,Lisa,New York, Human Resources".  In my power app, I just want the label to show the last name: Carslon.

 

I tried Split(ThisItem.Facilitator.DisplayName,",") but it doesnt' like this.  How can I do this?

 

Thanks,

Lisa

1 ACCEPTED SOLUTION

Accepted Solutions
Super User
Super User

Re: Splitting a sharepoint list item in power app label

I see why -- you don't have an embedded space between first and last which was what that keyed on.  Use this instead:

Left(ThisItem.TestPerson.DisplayName,Find(",",ThisItem.TestPerson.DisplayName)-1)
4 REPLIES 4
Super User
Super User

Re: Splitting a sharepoint list item in power app label

@LisaC 

 

Try this:

Left(ThisItem.TestPerson.DisplayName,Find(" ",ThisItem.TestPerson.DisplayName)-2)
LisaC
Level: Powered On

Re: Splitting a sharepoint list item in power app label

Thank you for your thinking on this but this didn't return the correct result .. this is what it returned: Carslon,Lisa,New York, Human

 

 

Super User
Super User

Re: Splitting a sharepoint list item in power app label

I see why -- you don't have an embedded space between first and last which was what that keyed on.  Use this instead:

Left(ThisItem.TestPerson.DisplayName,Find(",",ThisItem.TestPerson.DisplayName)-1)
LisaC
Level: Powered On

Re: Splitting a sharepoint list item in power app label

Bingo!  Thanks so much!  

Helpful resources

Announcements
firstImage

Watch Sessions On Demand!

Continue your learning in our online communities.

SecondImage

PowerApps Monthly Community Call

Next Wednesday, September 18th at 8am PDT

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

FirstImage

Power Platform World Tour

Coming to a city near you

thirdimage

PowerApps Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

FourthImage

Join PowerApps User Group!!

Connect, share, and learn with your peers year-round

SecondImage

Power Platform Summit North America

Register by September 5 to save $200

Users Online
Currently online: 186 members 4,684 guests
Please welcome our newest community members: