So I thought I had a fully working series of workflows - they finally tested great...most of the time. Then when I tried real world, I realized Get My Profile meant the owner of the flow not the person triggering. So...I found the option of Get User Profile - however when I choose that, I don't get the option in Dynamic Content to pick any kind of user fields for the UPN field - only gives me some field ones.
I thought what I was trying to do was simple, and had it working. Basically this is what I'm trying to get accomplished and now I'm under the gun, so I would really appreciate some expertise.
1. User uploads a file into Sharepoint Document Library (Submissions).
2. Submitting user receives email confirming their file was uploaded.
3. Approver receives email stating a file, filename.docx has been uploaded and requires their review.
4. Approver clicks link in email and takes appropriate action, Approve or Deny.
5. If Deny, submitter receives email stating submission was denied and description as to why.
6. If Approve, the file is copied over to One Drive and converted to pdf and deposited into Approvals folder in Sharepoint. (this part I have down I think)
7. Once converted to pdf, the approver and the submitter both receive notifications that the file has been approved, converted to pdf and available to download from Approvals folder.
I had this all working with 3 workflows, but the notifications are what's tripping me up. Every example I see where I try to edit it, the action steps provide different dynamic content options for me than what pictured. Can attach screenshots of the flows I have if that would help, but think this is one fo those times I just need to start from scratch with some expert help. Thanks in advance for your help.
What you need is the UPN (email address) of the user who's profile you want to retrieve. Depending on the trigger you are using you could get that from the metadata of the trigger. For example, the modified By property can get you the email of the user. Sometimes these complex values don't show up in dynamic data because they are objects and its looking for a string. The way to work around that is to create a variable and store the email just after the trigger fires. Then use the variable to get the profile. Post some screenshots or ask additional questions if you need more help.
Even the templates - such as :
Use the Get my Profile, which is why I am confused
Hi @welshiv ,
As you described, Get my profile action is to get the user info of the Flow Owner, or the user corresponding to the connection selected by this action.
The Get user profile action is used to obtain the info of any user in the tenant, as long as the UPN is provided.
If you want to get the info of the user who triggered the Flow, then you should use the Get user profile action.
You can use an Initialize Variable action to create a string variable and store the email for use later in the workflow. It looks to me like the email you want is for the person who originally uploaded the file. But I'm not sure why you want the profile for that person. Their email address and display name are available as properties of the Created By field.
Templates are examples that cover one situation. That template is not a perfect match for what you are trying to do.
Ok - I went with Send an email as the next step
and the email notification works, it send the email for approval. However, if you notice I no longer have the Start an Approval action - I instead had a Start and wait for an approval, so I chose that one. And then when I go to add the Condition - I no longer have Response - i now have Responses. When I run the test, it works, however, it's meeting the Approve condition as False, so it stops there, even though I do approve the file. Please see below:
You want Outcome, not Response. REsponse was used in the original version of the Approval Action. But that has been discontinued. The current version uses Outcome. Repsonses is a collection that contains all the responses, comments, approver names, etc.
Thanks!! @Pstork1 that worked for the first flow - thank you. However, now the Convert to PDF flow does not work- I simply did a Save As, new name and changed the folders in the flow - when I run the old one, works no problem - the copy creates the file on the One Drive but fails on the actual conversion - gives a BadGateway error. The only difference between the two is where the files are - 2 different folders, same root.
If you did a save as you may have to re-edit your dynamic data. It looks from your screenshot like something is wrong with the dynamic data being input as the filename when doing the file conversion.
Hi @welshiv ,
Please try this configuration:
First - thanks for the help!
However, the convert to pdf portion of this is so random - sometimes it works, most times it doesn't - no changes to flow, just seems completely arbitrary. I can't figure this out!
I'm getting Bad gateway everytime I test
Look out for new contribution recognition badges coming SOON!
Join us for the first ever Power Platform Online Conference!
We've updated and improved the layout and uploading format of the Power Automate Cookbook!
Fill out a quick form to claim your user group badge now!
Learn how to build the business apps that you need.
Find out where you can attend!
Watch & learn from the Power Automate Community Video Gallery!