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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Reset Image field afte...
Power Apps
Answered

Reset Image field after a Photo has been taken via Camera

(0) ShareShare
ReportReport
Posted on by Microsoft Employee

Hi,

New to Power Apps and like a lot of people I have seen on the forum I have been asked to build an app. One of the criteria of the app is that the camera function of power apps must be used.

 

Like the Title says I am having issues resetting an image that is linked to a camera.

 

Set Up:

 

Dropdown controls which camera the user wants to use on the device.

Tom_Dundon_0-1632391773655.png

The Camera then uses which ever camera is selected from the drop down. You need to select the camera field in order to take the picture.

Tom_Dundon_1-1632391962159.png

 

The photo that is taken then shows on an image field, you can retake the picture and the image field will change accordingly.

Before the image is taken the Image field is transparent and does not appear.

 

Tom_Dundon_2-1632392102466.png

 

Issue

The issue I am having is that I do not know how to reset the image field after a picture has been taken. I would Ideally need the image field to revert back to its original status of being transparent and not hold any Photo's that have been taken.

 

I have added a button and tried the following "OnSelect (property) Reset(Image4)" this has not worked but unfortunately I do not know the functions that would be best for the task.

 

Any help on this would be appriciated.

 

Thanks

Categories:
I have the same question (0)
  • Nogueira1306 Profile Picture
    7,390 Super User 2024 Season 1 on at

    Hey! You are using Camera1.Stream, right?
    If yes, set a var 


    Set(varPhoto, Camera1.Stream)

     

    If u want to re take the picture, click on a trash icon and set the OnSelect to Set(varPhoto, "")

     

    That will reset the photo 🙂 

     

    If you need additional help please tag me in your reply and please like my reply.
    If my reply provided you with a solution, pleased mark it as a solution ✔️!

    Best regards,
    Gonçalo Nogueira

    Check my LinkedIn!

    Check my User Group (pt-PT)!

     

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    @Nogueira1306 

     

    Thanks for the quick reply.

     

    I have not specifically set out to use Camera1.Sream.

     

    So just to confirm does the Set(varPhoto, Camera1.Stream) function need to be in the OnStream property of the Camera?

     

    I have added the Set(varPhoto,"") to the OnSelect property of the button, and no errors have shown.

    Tom_Dundon_2-1632397810376.png

     

    Thanks

     

     

     

  • Nogueira1306 Profile Picture
    7,390 Super User 2024 Season 1 on at

    1. Insert a Camera Control and set the StreamRate to 50 or 100;
    2. Add an icon (can also be the Camera Control) and write to OnSelect: Set(varPhoto; Camera1.Stream)
    3. Add an Image and set the image as the variable we created (varPhoto)

    4. Add an Icon to delete the image and write on OnSelect: Set(varPhoto; "")

     

    If you need additional help please tag me in your reply and please like my reply.
    If my reply provided you with a solution, pleased mark it as a solution ✔️!

    Best regards,
    Gonçalo Nogueira

    Check my LinkedIn!

    Check my User Group (pt-PT)!

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hi @Nogueira1306 , thanks again for your help.

     

    I am not sure what I am doing wrong here.

     

    I have added the camera control and set the stream rate to 100 (also tried at 50).

     

    The 'set(varPhoto; Camera9.Stream) in the 'OnSelect' property shows an error, "the formula contains 'Ident' when a 'Function' is expected".

     

    Tom_Dundon_0-1632402662395.png

     

    Tom_Dundon_3-1632403020572.png

     

     

    adding "varPhoto" was accepted.

    Tom_Dundon_1-1632402741457.png

     

    adding set(varPhoto, "") in the on select function was selected.

    Tom_Dundon_2-1632402774599.png

     

    Thanks

     

  • Verified answer
    Nogueira1306 Profile Picture
    7,390 Super User 2024 Season 1 on at

    You have 
    Set(varPhoto; Camera9.Stream)

    And it should be 

    Set(varPhoto, Camera9.Stream)

    Plus, I would recomend you do it on an icon and not on the camera control

     

    If you need additional help please tag me in your reply and please like my reply.
    If my reply provided you with a solution, pleased mark it as a solution ✔️!

    Best regards,
    Gonçalo Nogueira

    Check my LinkedIn!

    Check my User Group (pt-PT)!

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    You're 100% correct.

     

    I will add the Set(varPhoto, Camera9.Stream) to an icon, but I am limited for space due to the app requirements.

     

    Thank You for your help.

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 396 Most Valuable Professional

#2
11manish Profile Picture

11manish 134 Super User 2026 Season 2

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 101 Super User 2026 Season 2

Last 30 days Overall leaderboard