I built a flow with a recurrence schedule to run daily to archive or delete based on old files (older than 7 days) with user input from notification email. The issue is it also emails for approval about the folder names within Documents library - I just want to notify about the files within the folders or target a folder within the library. How do I do that?
Hey @BTHB
There is a SharePoint property that is called IsFolder.
If you use this you can check whether it is a file or folder.
If it is a folder you should do nothing, if it is a file you can do your other actions.
Hope this helps
Kind regards
Tom
If this reply has answered your question or solved your issue, please mark this question as answered.
Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up.
Thanks Tom
I tried this but I get no notification email at all because I set the value of isFolder to true and put my actions under "If no"
see below
heres the output of the flow
Hey @BTHB
I know it is annoying but you have to use the expression to make it equal to true.
So you have go into the field and choose Expression and type true and click the expression, then click Ok.
Kind regards
Tom
If this reply has answered your question or solved your issue, please mark this question as answered.
Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up.
Hi Tom,
I actually did do that as I understand how the expression works. It appears to be skipping the "if no" actions since the condition is true. The screenshot above is what the results are.
Thanks
HB
Hey @BTHB
Weird because if I replicate your Flow it works fine with me, well fine the Flow keeps running and I canceled the Flow but I still got the email for it.
So it is weird that your Flow doesnt want to go through.
And did you use the expression with true like i described in my previous message?
Kind regards
Tom
If this reply has answered your question or solved your issue, please mark this question as answered.
Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up.
Hi Tom
I will try again but I can also export my flow and send it to you if you like so you can see if you can reproduce the issue.
Thanks
HB
The condition is still not satisfied
Is it because i am using a nested condition?
Hey @BTHB
You can export your Flow, I will look into it.
And will let you know if I find something
Kind regards
Tom
If this reply has answered your question or solved your issue, please mark this question as answered.
Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up.
Hi @BTHB,
Could you please share a full screenshot of your flow's configuration?
Do you add two filter Conditions to check if the item is a folder within your flow?
I think it is not necessary to add two filter Conditions to check if the item is a folder within your flow, I have made a test on my side and please take a try with the following workaround:
Add a Condition, left input box set to IsFolder dynamic content of the "Get file metadata" action, right input box set to true, within middle drop down, choose is equal to.
Within "If/no" branch of Condition, add a Condition 2, click "Edit in advanced mode", type the following formula:
@equals(utcNow('MM/dd/yyyy'), formatDateTime(addDays(item()?['Created'], 7), 'MM/dd/yyyy'))
Within "If/yes" branch of Condition 2, add a "Start an approval" action.
Image reference:
Note: Under the "Start an approval" action, you could add other actions that you needed.
Best regards,
Kris
Kris thanks for the detailed flow! I attached the updated flow based on what you provided.
The flow does run successfully this time however it is still including the folders in the approval email, see below please. In this example, General is the folder name. If I choose an action, eventually I get a notification email for the documents in the folder but I want to exclude folders from in the notification email since the flow only works against files.
Attached is the flow built below
any update on this would be appreciated
bump
Hello, @BTHB!
Have you had an opportunity to apply @Diego‘s recommendation to adapt your Flow? If yes, and you find that solution to be satisfactory, please go ahead and click “Accept as Solution” so that this thread will be marked for other users to easily identify! Thank you for being an active member of the Flow Community!
-Gabriel
Flow Community Manager
Dive into the Power Platform stack with hands-on sessions and labs, virtually delivered to you by experts and community leaders.
Watch Nick Doelman's session from the 2020 Power Platform Community Conference on demand!
User | Count |
---|---|
40 | |
37 | |
36 | |
36 | |
28 |
User | Count |
---|---|
39 | |
39 | |
34 | |
30 | |
23 |