cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
drollercoaster
New Member

Question on folders and tagging

Hi all 

 

I am completely new to Power Apps, and I'm struggling. 

 

I have 2 requirements. First, imagine a folder structure like below:

 

Shared Documents

   +Country1

   +Country2

      +ProductName1

      +ProductName2

         +ProposalDocs

         +PricingDocs

         +ProductDescriptionDocs

 

If a document is uploaded into the country folder, I would like to tag the "Country" column with the of the folder name. For example, if a document is uploaded into "Country1", I would like to tag the "Country" column with the value "Country1".

 

If a document is uploaded into the productname folder, I would like to tag the "Product" and "Country" column with the appropriate values. For example, if a document is uploaded into "ProductName2", I would like to tag the "Product" column with the value "ProductName2" and the "Country" column with "Country2".

 

This same rule applies when a document is uploaded into the 3rd level subfolder, say, "ProposalDocs".

 

The maximum depth of subfolders is 3.

 

 

My second requirement is, how can I automate the creation of the 3rd level subfolders? When someone creates the folder Country2, nothing should happen. When they create "ProductName2", I would like an action to fire off that automatically creates the 3 subfolders of "ProposalDocs", "PricingDocs", and "ProductDescriptionDocs".

 

This is so frustrating. I am struggling trying to figure this out. Please help. Please also recommend some good books on Power Automate. 

 

 

1 REPLY 1

Hi @drollercoaster 

 

The approach to your first requirement would depend on your type of trigger. For example, I have used "When a file is created (properties only)" which gives me the ability to find the Folder Path. The folder path is dynamic content which I can then use to figure out where the document is stored.

 

But before we get into the whole process, have you considered using a document set in SharePoint rather than a folder for the country? That will allow you to specify metadata which is inherited by the documents within. That may help to reduce the complexity.

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

MPA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

Learn to digitize and optimize business processes and connect all your applications to share data in real time.

Power Automate Designer Feedback_carousel.jpg

Help make Flow Design easier

Are you new to designing flows? What is your biggest struggle with Power Automate Designer? Help us make it more user friendly!

Users online (1,674)