cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
MjnMixael
Frequent Visitor

Display complex data in Sharepoint Form

I have two use cases where I'm storing sets of data as a JSON array in a multi-line text field. I do this for Flow so I can pull it back out and find what I need and change things as necessary.

 

However, I'd like to display this data correctly in the Sharepoint View Form as edited by PowerApps. I didn't see a way to display JSON data nicely, which makes sense. So in Flow, I break out that data and save it in a different multi-line text field that should be more readable.

 

 

Name, time <br>
Name, time <br>

 

Or

Name, time <br>
---Comment <br>
Name, time <br>
---Comment <br>

The problem I'm having is that Powerapps HTML and RichText view fields are not respecting new lines. I've tried <br> and just a new line in the Flow Comp (which does indeed save correctly in Sharepoint). Neither works to clean up the display. I end up with...

Name, time <br>---Comment <br>Name, time <br>---Comment <br>

It word-wraps as necessary. However this isn't terribly readable. Is there a way I can get the working?

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Super User
Super User

Re: Display complex data in Sharepoint Form

@MjnMixael if your JSON is greater that 255 characters then yes, you should should store the data in a multiple-line Sharepoint column as plain text just like the picture below.

 

img2.png

 

Here's how the data would look while viewed Sharepoint.

 

img1.png

 

And here's how it looks in the PowerApp.  My gallery has the SP List JSONList as the datasource.  Then I added a HTMLText field and set the Text property to ThisItem.JSONified.

 

img3.png

 

Here's where to find the HTML Text field within the Insert menu.

 

img4.png

 

 

Let me know if this worked!

View solution in original post

3 REPLIES 3
Super User
Super User

Re: Display complex data in Sharepoint Form

@MjnMixaelto display the HTML new lines you'll have to save the data into a single-line text column within Sharepoint.  The HTML will only be interpreted if its stored in plain-text.  Rich-text won't work here.

 

Why not save the data into the Sharepoint List twice?  Once in a single-text column and again in a multi-line column.  You'll have readability and useablity: the best of both worlds. Smiley Happy

 

---

Please click "Accept as Solution" if my response helped to solve your issue so that others may find it more quickly.  If your thought the post was helpful please give it a "Thumbs Up."

MjnMixael
Frequent Visitor

Re: Display complex data in Sharepoint Form

I used multi-line because I'll probably go over the 255 character limit of single line. However, iirc, I can set multi-line to plain text. You think that will work?

Highlighted
Super User
Super User

Re: Display complex data in Sharepoint Form

@MjnMixael if your JSON is greater that 255 characters then yes, you should should store the data in a multiple-line Sharepoint column as plain text just like the picture below.

 

img2.png

 

Here's how the data would look while viewed Sharepoint.

 

img1.png

 

And here's how it looks in the PowerApp.  My gallery has the SP List JSONList as the datasource.  Then I added a HTMLText field and set the Text property to ThisItem.JSONified.

 

img3.png

 

Here's where to find the HTML Text field within the Insert menu.

 

img4.png

 

 

Let me know if this worked!

View solution in original post

Helpful resources

Announcements
MBAS Gallery 2020

MBAS Gallery 2020

Watch Microsoft Business Applications Summit sessions on-demand.

firstImage

New Ranks and Rank Icons released on April 21!

The time has come: We are finally able to share more details on the brand-new ranks coming to the Power Apps Community!

Power Platform 2020 release wave 1 plan

Power Platform 2020 release wave 1 plan

Features releasing from April 2020 through September 2020

Top Solution Authors
Top Kudoed Authors
Users online (5,110)