cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Anonymous
Not applicable

Saving Images to sharepoint

Hi, 

I have been trying to figure out how to save captured images from powerapps into my share point list. 

I have set up my camera and a button that captures the image. I wanted to be able to view my images in powerapps so I set up a gallery and form. But for some reason each image after the first one comes out blank, and not sure why. 

In my SP List I set up the image column as a multi-line column. Can someone please let me know if this isn't working because it's not possible or because I must have something wrong. Please see attached as to how my gallery and form look and my share point list. 

1 ACCEPTED SOLUTION

Accepted Solutions
v-xida-msft
Community Support
Community Support

Hi @Anonymous ,

How do you save the Captured Image data from your app to your SP List? Could you please share a bit more about the formula?

Could you please share a bit more about the ImageData column in your SP list? Is it a Multiple-line Text type column in your SP list?

 

I assume that the ImageData column is a Multiple-line Text type column in your SP list, is it true? Based on the issue that you mentioned, I think there is something issue with the formula you used to save captured images from your app to your flow.

 

I have made a test on my side, please take a try with the following workaround:5.JPG

 

 

6.JPG

 

7.JPG

Within the screen1, set the OnSelect property of the Camera control to following:

Collect(ImagesCollection, {PicName: "Captured Pic-"&Now(), PicContent: Camera1.Photo})

Note: Please use the OnSelect property of the Camera control to capture pictures rather than add another button to capture pics. If you use another button control to capture the pictures taken by Camera control, the captured image collection would include a blank value.

Set the OnSelect property of the "Upload to SP List" button to following:

ForAll(ImagesCollection, Patch('20190617_case14', Defaults('20190617_case14'),{Title: PicName, ImageData: PicContent}))

on your side, you should type following:

ForAll(
ImagesCollection,
Patch(
'YourSPList',
Defaults('YourSPList'),
{
Title: PicName,
ImageData: PicContent
}
)
)

The data structure of my SP list as below:8.JPG

 

Please consider take a try with above solution, then check if the issue is solved.

 

Best regards,

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
v-xida-msft
Community Support
Community Support

Hi @Anonymous ,

How do you save the Captured Image data from your app to your SP List? Could you please share a bit more about the formula?

Could you please share a bit more about the ImageData column in your SP list? Is it a Multiple-line Text type column in your SP list?

 

I assume that the ImageData column is a Multiple-line Text type column in your SP list, is it true? Based on the issue that you mentioned, I think there is something issue with the formula you used to save captured images from your app to your flow.

 

I have made a test on my side, please take a try with the following workaround:5.JPG

 

 

6.JPG

 

7.JPG

Within the screen1, set the OnSelect property of the Camera control to following:

Collect(ImagesCollection, {PicName: "Captured Pic-"&Now(), PicContent: Camera1.Photo})

Note: Please use the OnSelect property of the Camera control to capture pictures rather than add another button to capture pics. If you use another button control to capture the pictures taken by Camera control, the captured image collection would include a blank value.

Set the OnSelect property of the "Upload to SP List" button to following:

ForAll(ImagesCollection, Patch('20190617_case14', Defaults('20190617_case14'),{Title: PicName, ImageData: PicContent}))

on your side, you should type following:

ForAll(
ImagesCollection,
Patch(
'YourSPList',
Defaults('YourSPList'),
{
Title: PicName,
ImageData: PicContent
}
)
)

The data structure of my SP list as below:8.JPG

 

Please consider take a try with above solution, then check if the issue is solved.

 

Best regards,

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Hi @v-xida-msft 

 

I following your solution step byt step, even with the exact naming of the field and etc, but i get the blank gallery in screen 2.

 

what i do wrong?

 

blank url.png

joef
Continued Contributor
Continued Contributor

Hi @v-xida-msft,

Great post, but is there a way to actually display the image in SharePoint?

 

Thanks,

Joe

Helpful resources

Announcements
PA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

Welcome Super Users.jpg

Super User Season 2

Congratulations, the new Super User Season 2 for 2021 has started!

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

Top Solution Authors
Top Kudoed Authors
Users online (1,062)