cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
mtwining1
Helper I
Helper I

Get split to show rows in data table

I have an app that I want to convert a list from a SharePoint site for a column value into something that looks like list form in PowerApps. 

 

I have the split down no problem. I want to format the data table below so that those item numbers show as separate rows. How do I do this?

mtwining1_0-1642193789645.png

 

1 ACCEPTED SOLUTION

Accepted Solutions
rubin_boer
Super User
Super User

hi there @mtwining1  

 

if i get your requirement right, are you looking for something like this?

rubin_boer_0-1642194611582.png

In your case it will be

  • Add a gallery in your gallery (nested)
  • Set the Item = Split(ThisItem.'SAP Number', " ")

 

Hope this helps

R

 

View solution in original post

5 REPLIES 5
RandyHayes
Super User
Super User

@mtwining1 

Split will return a table of split results.  That table can be used as the Items property of any control that has an Items property.  So your Items property of the datatable should be the formula you show.

But, you are dealing with HTML text when you get the HtmlText from a rich text editor.  So assuming that spaces are what delimit your text is not guaranteed. 

I would change the formula to the following:

Split(PlainText(DataCardValue35.HtmlText), " ")

You don't need to trail this with a .Result as the function already returns a table with only a Result column.

 

I hope this is helpful for you.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up below. Solved your problem? - Click on Accept as Solution below. Others seeking the same answers will be happy you did.
NOTE: My normal response times will be Mon to Fri from 1 PM to 10 PM UTC (and lots of other times too!)
Check out my PowerApps Videos too! And, follow me on Twitter @RandyHayes

Really want to show your appreciation? Buy Me A Cup Of Coffee!
rubin_boer
Super User
Super User

hi there @mtwining1  

 

if i get your requirement right, are you looking for something like this?

rubin_boer_0-1642194611582.png

In your case it will be

  • Add a gallery in your gallery (nested)
  • Set the Item = Split(ThisItem.'SAP Number', " ")

 

Hope this helps

R

 

The results I am getting is no issue, the problem I have is how it's displayed. Instead of showing each item left to right, I want it to display from up to down.

 

Now Sample:

1087565 1087569 1087570 etc...

 

Desired Outcome:

1087565

1087569

1087570

etc..

Prefect and yes this was the desired outcome....granted I will make this look nicer, but have the functionality down now. Thanks.

 

mtwining1_0-1642195102677.png

 

RandyHayes
Super User
Super User

@mtwining1 

A Gallery is fine (and preferred), but the Datatable would have worked fine too.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up below. Solved your problem? - Click on Accept as Solution below. Others seeking the same answers will be happy you did.
NOTE: My normal response times will be Mon to Fri from 1 PM to 10 PM UTC (and lots of other times too!)
Check out my PowerApps Videos too! And, follow me on Twitter @RandyHayes

Really want to show your appreciation? Buy Me A Cup Of Coffee!

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

May UG Leader Call Carousel 768x460.png

June User Group Leader Call

Join us on June 28 for our monthly User Group leader call!

PA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

This training provides practical hands-on experience in creating Power Apps solutions in a full-day of instructor-led App creation workshop.

PA.JPG

New Release Planning Portal (Preview)

Check out our new release planning portal, an interactive way to plan and prepare for upcoming features in Power Platform.

Top Solution Authors
Users online (1,476)