1

I want to create a Flow to my SharePoint list to send a message to MS Teams. I am using the template "Notice the Team when specific document uploaded" (don't know the exact English wording for it, I have a Swedish version). I want it to trigger (answer "yes") when the uploaded document contains the word "report" in its filename. But it is never working. Trying to enclose the report word in quotation marks """, "'"..and so on. But no. In the Post messageScope step in Flow, I choose Filename, contains, and report. In advanced mode it looks like this:

@contains(triggerOutputs()['headers']['x-ms-file-name-encoded'], 'report')

Thankful for any guidance on this.

2

it won't work with the Dynamic expression of "File name" for contains you need your value to be a string, implement this as below screenshot that should work

enter image description here

EDIT- I tried playing with Flow output and here is my find the Dynamic property File Name is actually the mapped to x-ms-file-name-encoded which is the ID and not x-ms-file-name which contains the actual filename

enter image description here

So your contains statement also works if you replace it as below

@contains(triggerOutputs()['headers']['x-ms-file-name'], 'report')
|improve this answer|||||

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.