cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
reanm
Frequent Visitor

2 MS Flow issues: Flow button not appearing in list + converting to PDF on a "Apply to Each"

Hi there

 

I've seen the blog posts on how to convert an attached Notes document in Dynamics 365 to PDF.

All of these posts have it where the Trigger is "When a record (i.e. Note record) is created".

 

I have the requirement to trigger this operation by the end user i.e. using a Flow button.

 

When I use the (showing as deprecated) Dynamics 365 Button trigger, the Flow is listed in Dynamics.

However, when I use the Common Data Service Button trigger, the Flow is not available within Dynamics.

Any ideas?

 

Secondly, I'm getting an error when trying to convert the attached Note document on a Dynamics record, to PDF.

I've setup the first 2 steps (using the Dynamics 365 connector, as the Common Data Service one doesn't result in the Flow being visible in Dynamics) as shown in the screenshot below - these execute as expected:

 

Flow screenshot 3.JPG

My next step is to get a list of all the Notes records returned and then to perform the Convert to PDF action on each result.

However, I get an error when trying to do the convert to PDF step. I can see it's got to do with how I pass the Body of the Notes record, but I don't know how to fix this.

Flow screenshot 4.JPG

The expression that I'm using is:

base64ToBinary(triggerBody()?[items('Apply_to_each')])
 
Here's a screenshot of the error:
Flow screenshot 5.JPG
What am I doing wrong?

Thanks very much
Rean
1 REPLY 1
abm
Super User III
Super User III

Hi @reanm,

 

I managed to create a file using this way.

 

flowspfilecreation.png

 

When I ran my flow it did created the file in SharePoint.

 

Try the filename and filecontent to map from Dynamics properties.

 

Also I noticed that you are using filename as Test_SaleAgreement.docx in a loop. So if you have more than one attachments it will get overwritten.

 

Try the above mapping and let me know how it goes.

 

Thanks

 

 



Did I answer your question? Mark my post as a solution!

If you liked my response, please consider giving it a thumbs up


Proud to be a Flownaut!

Learn more from my blogPower Automate Video Tutorials

Helpful resources

Announcements
Process Advisor

Introducing Process Advisor

Check out the new Process Advisor community forum board!

MPA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

V3_PVA CAmpaign Carousel.png

Community Challenge - Giveaways!

Participate in the Power Virtual Agents Community Challenge

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

Carousel April Dunnam Updated 768x460.jpg

Urdu Hindi D365 Bootcamp

Dont miss our very own April Dunnam’s The Developer Guide to the Galaxy! Find out what the Power Platform has to offer for the traditional developer.

Users online (2,560)