cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
jslsmithyx
Helper II
Helper II

Issue with Compose Sub Folder

Hi guys, 

 

New to Power Automate & the community so please let me know if I've posted this in the wrong place! 

I'm attempting to follow the below guide which is for creating a flow so that tasks are created in MS Planner off the back of outlook emails (including attachments) 

https://www.alanps1.io/power-platform/flow/flow-create-planner-task-and-include-attachments-from-out...

I've followed the guide to a T, however the Flow Checker is returning this error & I'm unable to work out where the issue is:

'correct to include a valid reference to 'Get_Email' for the input parameter of action 'Compose'

This is in reference to the 'Compose Sub Folder' section of the guide, where I am inputting the below code into the inputs section: 

'concat(variables('TimeStamp'), '-' , body('Get_Email')?['Subject'])'

 

Would really like to get this Flow working & would appreciate any help on the matter. 

Tagging @AlanPs1 as advised in the comments section of the guide. 

 

Thanks in advance, 

 

Joe 

1 ACCEPTED SOLUTION

Accepted Solutions
efialttes
Super User
Super User

Hi

Right place to post!

Can you share a screenshot of your flow design?

 

Without it we are almost blind.

But just guessing... why don't you try

'concat(variables('TimeStamp'), '-' , body('Get_email')?['Subject'])'

 

Please note I am not using a capital letter for Email

Thanx!



Each time you click on any of our inspiring answers 'Thumb up' icon...
...an ewok scapes from the stormtroopers.

Be grateful, Thumbs up! Save the Galaxy for free!


Escribo sobre Power Automate en:
https://medium.com/anyone-can-automate/

Proud to be a Flownaut!



View solution in original post

19 REPLIES 19
efialttes
Super User
Super User

Hi

Right place to post!

Can you share a screenshot of your flow design?

 

Without it we are almost blind.

But just guessing... why don't you try

'concat(variables('TimeStamp'), '-' , body('Get_email')?['Subject'])'

 

Please note I am not using a capital letter for Email

Thanx!



Each time you click on any of our inspiring answers 'Thumb up' icon...
...an ewok scapes from the stormtroopers.

Be grateful, Thumbs up! Save the Galaxy for free!


Escribo sobre Power Automate en:
https://medium.com/anyone-can-automate/

Proud to be a Flownaut!



View solution in original post

Thanks so much for your speedy reply. 

 

I'd like to confirm that your suggested code seems to have resolved the issue (the difference not having a space can make, ey)! Not getting any more Flow Check errors, just need to test & make sure it works as expected. 

 

Once again thank you! 

 

@jslsmithyx 

Thanx for your kindness! The time spent marking this thread as solved will for sure help others in the future

Glad it worked



Each time you click on any of our inspiring answers 'Thumb up' icon...
...an ewok scapes from the stormtroopers.

Be grateful, Thumbs up! Save the Galaxy for free!


Escribo sobre Power Automate en:
https://medium.com/anyone-can-automate/

Proud to be a Flownaut!



No problem! I'm glad the community is so responsive, as I plan to do a lot more stuff with Power Automate

One more thing (sorry to keep revisiting an already closed post) but I've noticed one more thing which I'm a bit confused about. 

For some reason, the Flow I've built is recognizing pictures embedded in email signatures as attachments, and is provided links to these in the planner task along with the attachments themselves (the pictures are also being uploaded to the SharePoint location?). My company used about 7 images in our signatures so it means an additional 7 attachments per Planner task which is looking a bit messy. Please see attached - any ideas? Happy to provide my full flow if that'd help. 

 

Embedded pictures as attachment being uploaded to chosen sharepoint locationEmbedded pictures as attachment being uploaded to chosen sharepoint locationembedded pictures as  attachments being uploaded to planner taskembedded pictures as attachments being uploaded to planner task

 

Thanks so much again 

"For some reason, the Flow I've built is recognizing pictures embedded in email signatures as attachments"

 

Hi!

As far as I remember this is a Power Automate old limitation. THere are several threads discussing worarounds, one of the most populars is to add some sort of condition/filter array to removes the files whose extension is of type image, ... or the opposite, if you expect pdf attachments olny, just get the ones ending with .pdf

 

https://www.c5insight.com/Resources/Blog/tabid/148/entryid/871/video-how-to-filter-email-attachments...

 

Hope this helps



Each time you click on any of our inspiring answers 'Thumb up' icon...
...an ewok scapes from the stormtroopers.

Be grateful, Thumbs up! Save the Galaxy for free!


Escribo sobre Power Automate en:
https://medium.com/anyone-can-automate/

Proud to be a Flownaut!



Thank you for your reply - again 🙂 

 

I had a tinker around on the weekend, reviewing threads & trying to set up a filter to exclude .gifs from being uploaded to Sharepoint & linked to the Planner task but so far no luck 😞 

 

Flow Attachment problem 3.PNG

 

 

Above is a capture of the 'if' condition I believe is responsible for identifying whether there are attachments included on the email & whether these would be uploaded. The code for the 'Equals to' function is:

 

equals(body('Get_email')?['HasAttachment'], true)

 

If its not too much trouble, do you think you may be able to advise what this code should be to include all attachments except .gif files? 

 

Thanks for your help so far! 

 

 

 

 

Hi again!

I think both not() and endsWith() can do the magic you need, so it's just a question of identifying the trigger output providing attachment name with extension

In this thread you will find the opposite approach, they iterate through all attachments, and take the ones with a specific extension.

https://powerusers.microsoft.com/t5/Using-Flows/Filtering-attachments/td-p/188539

 

Flow_filter_attachment_ext.png

 

Hope this helps

 

 



Each time you click on any of our inspiring answers 'Thumb up' icon...
...an ewok scapes from the stormtroopers.

Be grateful, Thumbs up! Save the Galaxy for free!


Escribo sobre Power Automate en:
https://medium.com/anyone-can-automate/

Proud to be a Flownaut!



Managed to get it all working with your suggestions! Annoyingly the Flow is saying its failed even though all ticks are green for all scenarios etc but this is livable as it doesn't affect the flows functionality. 

 

Thanks very much for all your help! 

JRM05g
New Member

Hello,

 

I am having issues with the expression 

concat(variables(TimeStamp'),'-',body('Get_email')?['Subject'])'
 
It continues to give me a invalid expression, any help would be appreciated. 
Megan7
Regular Visitor

Hi!

 

Also new to the Power Automate Community. Hoping someone can give me a hand with a flow issue.

 

I am having the exact same issue as @jslsmithyx  however the solution isn't working for me. 

 

Is there anything else I can try, really need this flow to work

 

Thanks in advance for the help 🙂

I haven't used this flow in a long time now for various reasons but which part are you having issues with @Megan7? can you post screenshots and error messages? I'll do my best to help if I can.

Megan7_1-1626043867113.jpegMegan7_2-1626043887416.pngMegan7_3-1626043907434.png

 Hi, @jslsmithyx 

 

Thanks so much for your help. I have attached screenshots above, I have no idea what I'm doing wrong. It says the

 

Flow save failed with code 'InvalidTemplate' and message 'The template validation failed: 'The action(s) 'Get_email' referenced by 'inputs' in action 'Condition' are not defined in the template.'.'.  

at the top in red. 

You said you haven't used this flow in a while for various reasons, do you have another flow that you can recommended that will attach the email and it's attachments to a new task in planner? Or suggest another way I can do things?

 

Thanks again for your help, 

 

Megan 

Megan7
Regular Visitor

@jslsmithyx 

 

Hi, 

 

I realize I attached the wrong flow. I had been playing around with a new flow. This is the actual flow that I'm having trouble with, as well as the error message. 

 

Thanks, 

Megan

 

Megan7_0-1626050064366.jpeg

Megan7_2-1626050130843.pngMegan7_3-1626050151490.pngMegan7_4-1626050191658.pngMegan7_5-1626050207083.jpegMegan7_6-1626050220065.jpegMegan7_7-1626050235554.png

 

Thanks, can you also provide the full code for your 'Compose' Action please? 

 

Joe

Hi Joe,
 
See below,
 
concat(variables('TimeStamp'),'-',body('Get_email')?['Subject'])
 
Thanks, Megan 

Thanks. I'll take a look at recreating the flow on my side today to see what happens. 

In the meantime, can you try deleting & recreating your compose action? As well as deleting & recreating any references to it further down the flow. See whether you are still getting an error then. 

 

 

Thanks so much for the help, have deleted and recreated the flow with no luck unfortunately.

 

Megan  

Try

 

concat(variables('TimeStamp'),'-',body('Get_Email_(V2)')?['Subject'])

 

for your Compose.

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

M365 768x460.jpg

Microsoft 365 Collaboration Conference | December 7–9, 2021

Join us, in-person, December 7–9 in Las Vegas, for the largest gathering of the Microsoft community in the world.

Users online (1,900)