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

Save/Load images offline from camera

Hello,

 

I would like to use the camera to take an image, save it locally on my device (if the device has no internet connection) and upload the image to Sharepoint.

 

I already solved the uploading part to sharepoint but cant find any solution for saving the images. Seems like Savedata()/LoadData() cant be used for this?

 

I am thankful for some directions.

 

Thanks a lot

Joshua

2 ACCEPTED SOLUTIONS

Accepted Solutions
JoshuaCoordes
Level: Powered On

Re: Save/Load images offline from camera

Hey Andre,

just started to looking back into this today.

It looks like that this can be done now via adding the pictures from the camera control to a collection. I confirmed that the collection can be saved and loaded via the SaveData/LoadData functions.

 

To upload the pictures from the collection to Sharepoint I followed this steps: https://www.techmikael.com/2017/05/saving-collection-of-images-from.html

 

I will look into it more next week. Let me know what you think and if you get it done.

 

 

Super User
Super User

Re: Save/Load images offline from camera

I have an App that saves photos into a local collection (ClearCollect) and then uses the SaveData function to persist this to the device.

If(
    varIsSaveDataSupported,
    SaveData(
        Filter(colPhoto,IsBlank(ID)),
        "sdPhoto"
    )
);

Note varIsSaveDataSupported is a variable returning true or false. Only saving photos without an ID is related to method of offline synchronisation I'm using (photos without an ID to not exist in the database).

When the App starts the persisted data is loaded back into the local collection using the LoadData command

    LoadData(
        colPhoto,
        "sdPhoto",
        true
    );

I'm using SQL Server as my datasource, so it is easy to just 'collect' the photos into the table.

When I have done similar with SharePoint, I have patched or collected the Url data of the photo directly to a multiline text field in SharePoint. I have then put a Flow on the SharePoint list to take the Url data and save it as file in a SharePoint library.

9 REPLIES 9
Super User
Super User

Re: Save/Load images offline from camera

Hi @JoshuaCoordes

Are you using the Camera control (rather than Add Picture)?

Have you tried putting the image(s) from the Camera control in a collection and then using the Save/Load Data commands to store the collection locally?

samuelJ
Level 8

Re: Save/Load images offline from camera

Hi @JoshuaCoordes,

 

I tried looking into this a few months back.  I was told the ability to save pictures locally for offline use is currently not a supported feature.  You can save text, dates etc for offline use however.  

 

As far as I know this is still not a supported feature.  

Community Support Team
Community Support Team

Re: Save/Load images offline from camera

Hi @JoshuaCoordes,

 

It is true that so far you cannot download/save the images from PowerApps to local place. Please consider to add comment and vote in below idea thread which status is changed to under review:

https://powerusers.microsoft.com/t5/PowerApps-Ideas/Save-collection-to-the-local-device-as-an-Excel-...

 

Regards,

Mona

Community Support Team _ Mona Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
JoshuaCoordes
Level: Powered On

Re: Save/Load images offline from camera

Hey @v-monli-msft@samuelJ@PaulD1 thank you all for your quick replys. 

 

@PaulD1I was using the Camera Control but after saving the collection and reopening it via LoadData I connot use my Flow for uploading it to Sharepoint anymore as the data type is wrong:Unbenannt.PNG  

 

I will try to use the add image control, but the workaround in this tutorial to upload to sharepodoes not look simple for me: https://www.youtube.com/watch?v=mp-8B1fLrqs

 

Thanks again

 

Andre_Martins
Level: Powered On

Re: Save/Load images offline from camera

Hello everyone, do we have any update on this subject?

Thank you

JoshuaCoordes
Level: Powered On

Re: Save/Load images offline from camera

Hey Andre,

just started to looking back into this today.

It looks like that this can be done now via adding the pictures from the camera control to a collection. I confirmed that the collection can be saved and loaded via the SaveData/LoadData functions.

 

To upload the pictures from the collection to Sharepoint I followed this steps: https://www.techmikael.com/2017/05/saving-collection-of-images-from.html

 

I will look into it more next week. Let me know what you think and if you get it done.

 

 

Super User
Super User

Re: Save/Load images offline from camera

I have an App that saves photos into a local collection (ClearCollect) and then uses the SaveData function to persist this to the device.

If(
    varIsSaveDataSupported,
    SaveData(
        Filter(colPhoto,IsBlank(ID)),
        "sdPhoto"
    )
);

Note varIsSaveDataSupported is a variable returning true or false. Only saving photos without an ID is related to method of offline synchronisation I'm using (photos without an ID to not exist in the database).

When the App starts the persisted data is loaded back into the local collection using the LoadData command

    LoadData(
        colPhoto,
        "sdPhoto",
        true
    );

I'm using SQL Server as my datasource, so it is easy to just 'collect' the photos into the table.

When I have done similar with SharePoint, I have patched or collected the Url data of the photo directly to a multiline text field in SharePoint. I have then put a Flow on the SharePoint list to take the Url data and save it as file in a SharePoint library.

Andre_Martins
Level: Powered On

Re: Save/Load images offline from camera

Thank you for your share of knowledge @PaulD1 .

 

The advantage of using save and load instead of simply using a Collection is that when you turn off the App the information is saved in your device and with a Collection it is erased, is this correct?

 

Thank you.

 

 

Super User
Super User

Re: Save/Load images offline from camera

>>The advantage of using save and load instead of simply using a Collection is that when you turn off the App the information is saved in your device and with a Collection it is erased, is this correct?

 

Yes, that is correct.