web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Pen Input for Incident...
Power Apps
Unanswered

Pen Input for Incident Report

(0) ShareShare
ReportReport
Posted on by 725

I have a Diagram that I would like to draw where on a human body has suffered an injury. So when the form is submitted all the details of the incident, and the image would get saved too. Ideally when that report is recalled, I would like to see that same diagram and further edit the same image. I realise that when I save the pen input to Sharepoint that there will be no background image, but I was wondering what would be the best way of saving the Pen input to Sharepoint.

Categories:
I have the same question (0)
  • WarrenBelz Profile Picture
    153,030 Most Valuable Professional on at

    Hi @Corissandageri ,

    I have a blog on the various options of storing images in SharePoint. The one issue I can see however is that once you store an image, you cannot get it back and edit it.

    Happy to elaborate further if you find one of these options suitable.

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

  • R Bakker Profile Picture
    725 on at

    Thanks Warren

    I think I'll be checking out some other articles in your blog too.

  • R Bakker Profile Picture
    725 on at

    Hi Warren

    I have managed to save the PenInput to a Library and link it to my Sharepoint list. But I can't work out how to do it so that when I submit a form that it automatically submits the form and saves a single PenInput image with it. I have ditched the idea of re-editing the image when the record is recalled.

  • R3dKap Profile Picture
    1,594 on at

    @Corissandageri,

    Have you tried putting the code you created to save your PenInput inside the OnSuccess event of your form?

  • R Bakker Profile Picture
    725 on at

    I never thought of that, but how do I make the flow write to the same record instead of a new one?

  • WarrenBelz Profile Picture
    153,030 Most Valuable Professional on at

    @Corissandageri ,

    If you are saving to a Library, then you are obviously doing that with a Flow and you could run that on the form OnSuccess. I do mine the same way, except I use multi-line text fields in the list (hence not needing a Library or a Flow)

    I using a Library, you also need to "link" the signature to the form record - I do this with photos by storing the ID of the "Master" record in a field in the Library (I call it IDRef) and you can get it from Self.LastSubmit.ID if running on the OnSuccess. One thing to watch however is to make signature input compulsory, or you will send over a blank signature. For this reason also, if the form is edited, you need to make the running conditional on there being something in the signature.

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

     

     

  • R Bakker Profile Picture
    725 on at

    Well I went down the road of a using a Flow, but I would prefer not to. So what would I have to change for a pen input re your article here?

  • WarrenBelz Profile Picture
    153,030 Most Valuable Professional on at

    @Corissandageri ,

    I have never tried that one as the output of the camera control is different (it is stored in a format called dataUri ).

    I was referring to this article (and I actually did one today) using a multi-line text field.

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

  • R3dKap Profile Picture
    1,594 on at

    @Corissandageri, personally I store camera photos or pen input signatures as real images inside a SharePoint library because then I can view them when I go to SharePoint (which is not the case if you store its binary data in a multi-line text field as @WarrenBelz describes). Not criticizing Warren's solution which works fine. Just saying I don't do it that way.

    Meaning, that I do use a flow to store/update my pictures on SharePoint.

    About saving images from Power Apps to SharePoint using a flow, I do it very simply this way:

    • on the Power Apps side, I call the flow:
    SaveImage.Run(MasterRecord.ID, JSON(PenInput.Image, JSONFormat.IncludeBinaryData)
    • on the Power Automate flow side, I first create the file in the library using this code to set the file content (strSignature being the parameter retreiving the JSON value from Power Apps):
    base64ToBinary(split(replace(variables('strSignature'),'"',''),',')[1])
    • then I update the properties of the newly created file to link it to my master list record

    Note that in Power Apps, you will only be able to access the thumbnails for the images you stored in your library. You have access to 3 sizes of thumbnails though: small, medium, large.

  • WarrenBelz Profile Picture
    153,030 Most Valuable Professional on at

    @R3dKap ,

    That is how I do my Photos (slight variation in the JSON conversion - I do the splitting in Power Apps).

    I always use a PowerApps integrated form in my SharePoint lists, so I can view the signature in there.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 796 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 327 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard