Hi Guys,
I've got an attachment control (named AttachmentControl-1) that allows users to upload their attachments (images) and i'd like for them on the next screen to be able to see all images that they've uploaded in a gallery.
In addition to this, i'd like the users to be able to use the Camera feature and take a photo or in some cases, several photos and add these pictures to the same collection (which i've named colImages).
Thanks in advance!
Hi @Dave-ITMan ,
Firstly, I assume you are collecting unsaved attachments ? You will not get any content from saved/uploaded items and therefore no images, otherwise ThisItem.ContentBytes should show the image and yes, ThisItem.Name should show the file name (saved or unsaved).
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.
Visit my blog Practical Power Apps
Hi @WarrenBelz ,
Thank you, i've followed your guide and I've uploaded 2 pictures using the attach file button but when I look at the gallery, it's only showing me the names of the files i've uploaded and not showing the images. 2nd point is how do I include any pictures taken with the camera icon to also go into the same collection (colImages) as the rest of the images please?
What i've done is:
gallery named galAttachments
Items property of galAttachments set to colImages
Image control of the first image in the gallery Image property set to ThisItem.ContentBytes
Set the Text property of the first label to ThisItem.Name
Hi @Dave-ITMan ,
The images should display with
ThisItem.ContentBytes
Your process looks very similar to this blog of mine.
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.
Visit my blog Practical Power Apps
Hi @WarrenBelz
Thanks for the info, i've had a look and it doesn't seem to be the same scenario i'm looking for. I've already setup a submit button that emails the results and attachments and then use patch to send the results to a sharepoint list and then Flow will move the attachments into the sharepoint list.
I have colImages which is the image collection and I have AttachmentControl-1.Attachments. Below is the code I have in the submit button but all I want to do is add all of the images from the camera into the colImages so that all of the attachments are together and can view anything uploaded or taken via the camera in a gallery.
ClearCollect(
colImages,
AddColumns(
RenameColumns(
'AttachmentControl-1'.Attachments,
"Value",
"ContentBytes"
),
"@odata.type",
""
),
{
Name: "Signature.jpg",
ContentBytes: 'Signature-1'.Image
}
);
Office365Outlook.SendEmailV2("email@domain.com" , 'Result-Job-Number'.Text , "Hi,<br><br>
Please see completed form below and attached photos<br><br>
Regards<br><br>
IT<br></br>",
{Attachments: colImages}
);
Patch(Portal, Defaults(Portal),
{
Hi @Dave-ITMan ,
Most of the first part is in this blog of mine and camera control process in this video
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.
Visit my blog Practical Power Apps
WarrenBelz
146,524
Most Valuable Professional
RandyHayes
76,287
Super User 2024 Season 1
Pstork1
65,906
Most Valuable Professional