Hi, I am creating an APP where the employees in my company have to key in the defects of the machine that they are operating and take photos of the defects in the form that I have created. After submitting the form, the screen will navigate to the summary page which will show details of the defects that they keyed in and the photos they have taken. However, it seems like I am unable to keep the images they took because every time a new photo is taken using the camera function, all the images in summary page will change to be the latest image taken. I have attached pictures of my APP in this post.
First Attachment: This is the form that I have created where the employees can click on "Take Photo" and they will navigate to the "Camera" screen
Second Attachment: This is the "Camera" screen with the capture button that has the formula Collect(MyPicture, MyCamera.Photo); Navigate(Image, ScreenTransition.None). After they capture an image, they will navigate to the "Image" screen to have a preview
Third Attachment: This is the summary page where the photos of defects are supposed to be. I have changed the "Image" property of the image to be "MyCamera.Photo"
Can someone tell me where I am doing wrong? Thank you!
Ah, I know what the issue is here. Only the OnSelect property of the camera control is capable of getting a new photo.
If you use the icon's OnSelect property, it will only get the most recent image taken by the camera.
You will need to move your logic to the Camera control's OnSelect property.
Hi, I have tried to move the formula Collect(MyPicture, MyCamera.Photo) to the camera's OnSelect property but this problem still persists. I tried to submit 2 forms and took 2 different photos but the photo in the first form will update to be the photo taken using the second form. Can you please help me with this? Thank you!
@Anonymous, it sounds like you moved this formula to the Camera.OnSelect
You need to take pictures by clicking the camera now.
Then on the next screen, you'll want to point the Image control to
Last(MyPicture).Value so it shows the last image in the collection.
Hi, I think you misunderstood what I meant.
I would like to have a camera function in my APP which the employees can use to take photos of the defects that they encounter, and submit the photo together with the form.
And in the summary page after submitting the form, they should be able to see the photos of the defects that they took. However, whenever a new photo is taken by the camera, all the images in the summary page will be changed to be the latest image captured by the camera.
Here are the properties:
Camera's OnSelect Property:
Collect(MyPicture, MyCamera.Photo); Navigate(Image, ScreenTransition.None)
Hello @Anonymous ,
There seems to be a couple of things going on here. In your initial setup you were using a button/icon to add the Mycamera.Photo to the collection and navigate, this will not work because the photo only gets taken once the user presses on the Camera control.
Now what @Mr-Dang-MSFT was suggesting is that you remove the Button Icon and use the camera control to Collect and navigate to the new screen. There is however another solution that will allow you to use the Icon to take the picture using MyCamera.Stream and you can find more details here (Link).
If I understand correctly it seems that when you connect the image control in your photo defect summary you use the MyCamera.Photo instead of using the photo from the collection. I would suggest that you try to create a gallery that uses the photo collection and display the images from each Item to see if these images are preserved after you take your new photo.
Hope this helps 🙂
Alright let's look at each issue seperately. So in your summary page, you mention that your Image property is set to MyCamera.Photo which is the last photo taken by your Camera control ... Instead you need to set it to the image property to show the image for the entry in your collection.
Check it out!
Check it out!
Fill out a quick form to claim your user group badge now!
Find out where you can attend!
Features releasing from October 2019 through March 2020
The largest Power BI, Power Platform, and Data conference in New Zealand