Shane, thank you so much for this video! It's been so helpful! I am a total beginner here and have been finding it rather frustrating getting some things to work. What I am aiming at is, when someone uploads a file in PowerApps, I want this file to go into a folder in a SharePoint library that contains the name of the legal entity of the related task in PowerApps. With your help, I have managed to use dynamic folders and this is working really well. My issue now is removing a file from that SharePoint folder when this is deleted in PowerApps. I just haven't figured out how to do that.
Thanks for this amazing video! I have a question... Has anyone tested the attachment control related to how many files and size can be uploaded to a library at once?
Nice video. The only thing I question is the extended "If" logic with the blank "Project Number". Why not set the DisplayMode of the File Upload control to "Display" when either condition is blank, and "Edit" when both are not? That way, they could not select a file until the required information is already entered, and it simplifies the logic in the addfile routine.
Thanks, your videos have really helped my understanding of Power Apps. Is there any way of sending multiple person records to a Person or Group field as meta data fields when uploading a file in sharepoint using flow? I've previously done it with patch?
Yes, it is the very similiar. Go to flow, add the multi-person field to the action and manually configure it. Then look at the Code view. It will show you what it needs. Then you need to send the info over in that format so you can plug it in. :)
Great content as always! I have a question. I have a toggle button before attaching the files. When toggle is on, create the folder / file on this SP folder. If toggle is off then create it on this other SP folder. Sounds simple but not sure how to incorporate in the flow. Appreciate your help Shane! :)
Oh I figured out a workaround by creating 2 flows and using value of toggle to set visibility of flows! :) I have another question...if I want to share the folder link instead of the file link? How can that be achieved? Thank you!
Hey Shane - I have a question on storage solutions for uploads. Which is better using Dataverse to store documents (PDF's, TIF's, etc) as an attachment or using Sharepoint? I love your videos they have meant the world to me in my quest to become a better powerapps developer. You are always at the top of my feed to watch. Thank you for all that you do and share with the community.
@@ShanesCows I'm developing my project using dataverse and the expense side isn't the main concern. I'm shooting for something that is a document management solution for our AP / AR system so parties with buy in to the documents can view documents on the fly for approvals or general information. So i wasn't sure which solution would be more responsive and allow for dynamic uses down the road. Think attaching proof of receipt to invoices when we invoice customers.
Amazing Video, Is it possible to check how many items are in a folder and if the quantity of items its the same doesnt let the user save a form? And is it possible to check a folder inside a folder for the same reasons? Thanks Shane you have help me severous times!
Yes. The best I can offer to help is this video where I built a document library explorer. You will see how I dealt with folders. ua-cam.com/video/u-b8w9ea1kk/v-deo.html
Shane thank you for this video, May I ask, I want to use a toggle button in Power Apps to upload an attachment to an Attachments element before sending an email, so I don't have to upload it every time. How can I do this?
@@ShanesCows sorry shane for my bad English, "I have a predefined email directly in PA that sometimes needs to include a PDF file 'Doc1'. I want to have a toggle next to it that attaches the file when pressed, so the end user doesn't have to upload the file each time."
Hi Raza Dorrani, I want the document library app that you showed in the last video ending. Is there any way to get that app, or do you have a link to share with me? It would be helpful to me.
I developed an app that needs access to upload files to a SharePoint document library, in a folder with the ID of the form as the folder name. I created the record and then navigate to a popup like screen with a button that kicks off a flow to create the folder. I used to create the folder on the creation of the form record, but the customer didn't want to have to reopen the form to upload files. I will watch this and hopefully just navigate them to an upload screen post form creation. Until now, I had a hard time uploading to a folder using the form ID as the name.
Is there a way to get internal file metadata of uploaded files? The use case I’m looking for is for PDF files to get internal file metadata to understand if the file was modified after creation
@@radhikaseetharaman1772 if I under stand what your asking yes. This is the code I have in my on select button that I would like for it to activate on. I’m and getting errors on Last(FILE).Value & Last(FILE).Name & Reset(Self) ForAll(Attachmen_1_DatacardValue_4.Attachments As FILE, CARAttachmentFlow.Run( inpFN.Text, InpPN.Text, { file:{ contentBytes:Last(FILE).Value, name: Last(FILE).Name } } )); Reset(Self);
@@radhikaseetharaman1772 Remove the word "Last" and the brackets around "FILE", so that part of your formula will read like this: contentBytes:FILE.Value, name:FILE.Name
Is it possible to add text to a file name before the file extension? For example, the file name is "My File.txt" and the uploaded file should "My File 123.txt". I tried to do a concatenate instead of substitute to add the required text to the end of the file name, but this adds the text after the extension... My File.txt123
Yes, would be a tad tricky though. If your file will ever only have one . then you could substitute(filename, ".", "123.") something like that. Or if you know your extention will always be .txt you could do similar.
@@ShanesCows Thank you for giving me a much easier formula. If you think that's tricky, just wait until you see what I came up with. I kept kept trying to figure it out after I asked my question and I got it to work with concatenate and split. This is my super tricky formula: Concatenate(First(Split(File.Name, ".")).Value & "-" & Text(Now(),"hhmmss") & "." & Last(Split(File.Name, ".")).Value)
@@ShanesCows Your comment about only one "." in the file name has been bugging me. Most of the users in my organization do not put periods in a file name, but there is always that one person that will mess it up. I added a couple things to prevent a file from having more than one period. I added this formula to a label's text property that displays a message if an attachment in the attachments control has too many periods: If(!IsEmpty(Attachment_Conrol_1.Attachments), With({wAttachmentCheck: ForAll( Attachment_Conrol_1.Attachments As File, If(CountIf(Split(File.Name,""), Value = ".") > 1, "Error", "Valid")) }, If("Error" in wAttachmentCheck, "Periods in file name not allowed", Blank()) ),Blank()) On the save button I added this to disable it if the file name has too many periods: With({wAttachmentCheck: ForAll( Attachment_Conrol_1.Attachments As File, If(CountIf(Split(File.Name, ""), Value = ".") > 1, "Error", "Valid")) }, If("Error" in wAttachmentCheck), DisplayMode.Disabled, DisplayMode.Edit)) I am assuming there may be a much easier way to do this, but this seems to be working so far.
Yes, I show it in this video ua-cam.com/video/cjcDH7_v6cE/v-deo.html The key is you put the code you ahve in the Save button in the OnFileAdd property of the attachment control
Could you do a video showing how to do this using OneDrive for Business storage? I'm trying to duplicate the same thing that the Site Inspection template app does. I've been trying to understand this for about 2 weeks and I just can't figure out how it's doing it. The app uses a folder in OneDrive to hold the pictures and an Excel file to store the path to the pictures. This is my white whale. As far as I can tell, it does not use Power Automate or a Flow.
@@ShanesCows That's useful info but I'm not sure how it applies to my question. Are you thinking that the image is being stored in the excel file?? Thanks for the quick reply!!!!
@@ShanesCows Theres no specific file system function for "Create Folder" when writing to an on-prem network via the gateway. Kinda annoying. I did some digging around and cannot see a work around at all. The path is the final destination so you cant even tag a folder into the path. C:\My Folder\FolderName\FolderPath
Interacting with files desperately needs a revamp. Using power automate to upload files is not ideal. Once a file is uploaded, we should have a way to rename them within the power app. We have a solution where users need to change the date embedded in the file name, but we want to keep the file uploaded date to stay the same. There are so many features lacking. Licensing also really needs to be a lot easier. As much as this is all good, we would be satiated by having more robust features when it comes to files. Thanks for sharing this info, it’s great but I can’t wait to see Microsoft make some really useful changes.
@MachineMirth - FYI: You don’t need to use a flow to upload to SharePoint docs library. You may have known that already. This is just another way of doing it, which looks pretty nice. Thanks Shane!
Shane, thank you so much for this video! It's been so helpful! I am a total beginner here and have been finding it rather frustrating getting some things to work. What I am aiming at is, when someone uploads a file in PowerApps, I want this file to go into a folder in a SharePoint library that contains the name of the legal entity of the related task in PowerApps. With your help, I have managed to use dynamic folders and this is working really well. My issue now is removing a file from that SharePoint folder when this is deleted in PowerApps. I just haven't figured out how to do that.
This video I show how I built a full document library explorer. Included uploads, previews, and DELETEs 😎 ua-cam.com/video/u-b8w9ea1kk/v-deo.html
@@ShanesCows Many thanks for sharing that! How did I miss that one? 🙂 Going straight into it. Thank you!!!
Another great video, bravo ... definitely signing up for your training classes soon
Awesome, thank you!
Thanks for this amazing video! I have a question... Has anyone tested the attachment control related to how many files and size can be uploaded to a library at once?
Nice video. The only thing I question is the extended "If" logic with the blank "Project Number". Why not set the DisplayMode of the File Upload control to "Display" when either condition is blank, and "Edit" when both are not? That way, they could not select a file until the required information is already entered, and it simplifies the logic in the addfile routine.
I don't hate that Jeff. 🤩 The fun of Power Apps, there is usually 10 ways to do everything.
Great video. I really enjoyed that and picked up a number of tips. Thanks
Glad it was helpful!
Nice one. Saved/Bookmarked for reference in the future. As always, thanks for sharing Shane. 💥💥
You bet!
Thank you Shane
Happy to help. Have a great week!
Thanks, your videos have really helped my understanding of Power Apps. Is there any way of sending multiple person records to a Person or Group field as meta data fields when uploading a file in sharepoint using flow? I've previously done it with patch?
Yes, it is the very similiar. Go to flow, add the multi-person field to the action and manually configure it. Then look at the Code view. It will show you what it needs. Then you need to send the info over in that format so you can plug it in. :)
@@ShanesCows Thanks for the speedy response, I will give it a try. As you say - It keeps getting angry at me!! :)
Helpful 🎉
Glad it was helpful!
Great content as always! I have a question. I have a toggle button before attaching the files. When toggle is on, create the folder / file on this SP folder. If toggle is off then create it on this other SP folder. Sounds simple but not sure how to incorporate in the flow. Appreciate your help Shane! :)
Oh I figured out a workaround by creating 2 flows and using value of toggle to set visibility of flows! :) I have another question...if I want to share the folder link instead of the file link? How can that be achieved? Thank you!
Love it. Good job
Great Shane. Nice touch on Buddy Pics😂
Thanks! Always like to sneak in the dog 🐶
Hey Shane - I have a question on storage solutions for uploads. Which is better using Dataverse to store documents (PDF's, TIF's, etc) as an attachment or using Sharepoint? I love your videos they have meant the world to me in my quest to become a better powerapps developer. You are always at the top of my feed to watch. Thank you for all that you do and share with the community.
I think it is easier and cheaper to store them in SharePoint. :) Of course depends on exactly what you are building but that is where I start from.
@@ShanesCows I'm developing my project using dataverse and the expense side isn't the main concern. I'm shooting for something that is a document management solution for our AP / AR system so parties with buy in to the documents can view documents on the fly for approvals or general information. So i wasn't sure which solution would be more responsive and allow for dynamic uses down the road. Think attaching proof of receipt to invoices when we invoice customers.
Hello! At 18:14 we can see a new green icon "+" (not Paper clip). How did you change the icon?
It is an Icon on top of an invisible paper clip. I show doing that in this video I am pretty sure. ua-cam.com/video/cjcDH7_v6cE/v-deo.html
Amazing Video,
Is it possible to check how many items are in a folder and if the quantity of items its the same doesnt let the user save a form? And is it possible to check a folder inside a folder for the same reasons?
Thanks Shane you have help me severous times!
Yes. The best I can offer to help is this video where I built a document library explorer. You will see how I dealt with folders. ua-cam.com/video/u-b8w9ea1kk/v-deo.html
Shane thank you for this video, May I ask, I want to use a toggle button in Power Apps to upload an attachment to an Attachments element before sending an email, so I don't have to upload it every time. How can I do this?
Sorry, I am not following. Can you try explaining again?
@@ShanesCows sorry shane for my bad English, "I have a predefined email directly in PA that sometimes needs to include a PDF file 'Doc1'. I want to have a toggle next to it that attaches the file when pressed, so the end user doesn't have to upload the file each time."
Hi Raza Dorrani, I want the document library app that you showed in the last video ending. Is there any way to get that app, or do you have a link to share with me? It would be helpful to me.
I developed an app that needs access to upload files to a SharePoint document library, in a folder with the ID of the form as the folder name. I created the record and then navigate to a popup like screen with a button that kicks off a flow to create the folder. I used to create the folder on the creation of the form record, but the customer didn't want to have to reopen the form to upload files. I will watch this and hopefully just navigate them to an upload screen post form creation. Until now, I had a hard time uploading to a folder using the form ID as the name.
Hopefully this gets you everything you need. 😎
@ShanesCows It does. I am very happy. Thanks, Shane!
Is there a way to get internal file metadata of uploaded files? The use case I’m looking for is for PDF files to get internal file metadata to understand if the file was modified after creation
Maybe, but I have never done it or tried, so I don't know.
Is there any way we can get excel sheet in power automate for comparing the headers value for two different sheets without being formatted as table?
Will this also work with multiple -file uploads? Excellent video.
Yes it will. I am pretty sure I cover multi in this video ua-cam.com/video/cjcDH7_v6cE/v-deo.html
@@ShanesCows Yes, I have watched that video as well. I am just having trouble translating that code to a button control like the other video.
Hi @LaurenBolin do you have solution for multiple file uploads??
@@radhikaseetharaman1772 if I under stand what your asking yes. This is the code I have in my on select button that I would like for it to activate on. I’m and getting errors on Last(FILE).Value & Last(FILE).Name & Reset(Self)
ForAll(Attachmen_1_DatacardValue_4.Attachments As FILE,
CARAttachmentFlow.Run(
inpFN.Text,
InpPN.Text,
{
file:{
contentBytes:Last(FILE).Value,
name: Last(FILE).Name
}
}
));
Reset(Self);
@@radhikaseetharaman1772 Remove the word "Last" and the brackets around "FILE", so that part of your formula will read like this: contentBytes:FILE.Value, name:FILE.Name
Is it possible to add text to a file name before the file extension? For example, the file name is "My File.txt" and the uploaded file should "My File 123.txt". I tried to do a concatenate instead of substitute to add the required text to the end of the file name, but this adds the text after the extension... My File.txt123
Yes, would be a tad tricky though. If your file will ever only have one . then you could substitute(filename, ".", "123.") something like that. Or if you know your extention will always be .txt you could do similar.
@@ShanesCows Thank you for giving me a much easier formula. If you think that's tricky, just wait until you see what I came up with. I kept kept trying to figure it out after I asked my question and I got it to work with concatenate and split. This is my super tricky formula: Concatenate(First(Split(File.Name, ".")).Value & "-" & Text(Now(),"hhmmss") & "." & Last(Split(File.Name, ".")).Value)
@@alexw190 Working is better than not working. 🤩🤩
@@ShanesCows Your comment about only one "." in the file name has been bugging me. Most of the users in my organization do not put periods in a file name, but there is always that one person that will mess it up. I added a couple things to prevent a file from having more than one period.
I added this formula to a label's text property that displays a message if an attachment in the attachments control has too many periods:
If(!IsEmpty(Attachment_Conrol_1.Attachments),
With({wAttachmentCheck:
ForAll(
Attachment_Conrol_1.Attachments As File,
If(CountIf(Split(File.Name,""), Value = ".") > 1, "Error", "Valid"))
},
If("Error" in wAttachmentCheck, "Periods in file name not allowed", Blank())
),Blank())
On the save button I added this to disable it if the file name has too many periods:
With({wAttachmentCheck:
ForAll(
Attachment_Conrol_1.Attachments As File,
If(CountIf(Split(File.Name, ""), Value = ".") > 1, "Error", "Valid"))
},
If("Error" in wAttachmentCheck), DisplayMode.Disabled, DisplayMode.Edit))
I am assuming there may be a much easier way to do this, but this seems to be working so far.
Is there a way to make the file automatically save to my split when a user add a file as file attachement, where they won't have to click Save/Submit?
Yes, I show it in this video ua-cam.com/video/cjcDH7_v6cE/v-deo.html
The key is you put the code you ahve in the Save button in the OnFileAdd property of the attachment control
Could you do a video showing how to do this using OneDrive for Business storage? I'm trying to duplicate the same thing that the Site Inspection template app does. I've been trying to understand this for about 2 weeks and I just can't figure out how it's doing it. The app uses a folder in OneDrive to hold the pictures and an Excel file to store the path to the pictures. This is my white whale. As far as I can tell, it does not use Power Automate or a Flow.
Excel has an image column type. If you set that up in your Excel then Power Apps understands it.
@@ShanesCows That's useful info but I'm not sure how it applies to my question. Are you thinking that the image is being stored in the excel file?? Thanks for the quick reply!!!!
@@ShanesCows I just dug through a download of the app and found that they are using api calls to do the onedriveforbuisness calls. Cheaters!!!
:( I so wanted this to include some clever stuff for creating folders in an on premise environment :(
aka file system "create folder"
Does creating folders on-prem not work the same way as online? I have never had to work with on-prem SP and flow.
@@ShanesCows Theres no specific file system function for "Create Folder" when writing to an on-prem network via the gateway. Kinda annoying. I did some digging around and cannot see a work around at all. The path is the final destination so you cant even tag a folder into the path. C:\My Folder\FolderName\FolderPath
Interacting with files desperately needs a revamp. Using power automate to upload files is not ideal. Once a file is uploaded, we should have a way to rename them within the power app. We have a solution where users need to change the date embedded in the file name, but we want to keep the file uploaded date to stay the same. There are so many features lacking. Licensing also really needs to be a lot easier. As much as this is all good, we would be satiated by having more robust features when it comes to files. Thanks for sharing this info, it’s great but I can’t wait to see Microsoft make some really useful changes.
Making uploads easier, I think we would allow vote for that feature. 🙂
@MachineMirth - FYI: You don’t need to use a flow to upload to SharePoint docs library. You may have known that already. This is just another way of doing it, which looks pretty nice. Thanks Shane!