cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
BigE
Level: Powered On

Flow no longer working - Property selection is not supported on values of type 'String'

I have a Flow that has been working flawlessly up until 2 weeks ago. Now, each time I run the flow I get the following error: 

 

InvalidTemplate. Unable to process template language expressions in action 'Append_to_array_variable' inputs at line '1' and column '2330': 'The template language expression 'body('Get_attachment_content')?['$content']' cannot be evaluated because property '$content' cannot be selected. Property selection is not supported on values of type 'String'. Please see https://aka.ms/logicexpressions for usage details.'.

 

This particular flow is supposed to send multiple attachments in an email when a new SharePoint list item is created. This WAS working just fine but all of a sudden stopped.

 

In order to get the $content for "ContentBytes", I used the following expression: body('Get_attachment_content').$content and it saved as $content. Detailed steps for this Flow can be found on my blog: Emailing List Attachments in Office 365

 

I have added a screenshot of the Flow itself. Any help on this would be greatly appreciated, I have just about given up on this.

 

GetImage.png

 

1 ACCEPTED SOLUTION

Accepted Solutions
Community Support Team
Community Support Team

Re: Flow no longer working - Property selection is not supported on values of type 'String'

Hi @BigE,

 

Could you please show a bit more about the Attachment files of the new created item?

 

I have made a test on my side and don't have the issue that you mentioned. My flow's configuration as below;10.JPG

 

11.JPG

Within "Append to array variable" action, Value field set to following json data:12.JPG

The corresponding value of the ContentBytes key set to following formula:

body('Get_attachment_content')?['$content']

Note: The Attachment files are PDF file and Excel file on my side.

 

The flow works successfully as below:13.JPG

14.JPG

 

 

The error message told that the $content property could not detected using the 'body('Get_attachment_content')?['$content']' within your "Append to array variable" action. I have made a test on my side, if the attachment file is a .txt file, the error would show up as you mentioned.

 

Please check if the Attachment files of the new created item contain .txt file, if the Attachment files contain .txt file, the result the 'body('Get_attachment_content')?['$content']' expression returned doesn't contain the $content property.

 

 

Best regards,

Kris

 

 

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
Community Support Team
Community Support Team

Re: Flow no longer working - Property selection is not supported on values of type 'String'

Hi @BigE,

 

Could you please show a bit more about the Attachment files of the new created item?

 

I have made a test on my side and don't have the issue that you mentioned. My flow's configuration as below;10.JPG

 

11.JPG

Within "Append to array variable" action, Value field set to following json data:12.JPG

The corresponding value of the ContentBytes key set to following formula:

body('Get_attachment_content')?['$content']

Note: The Attachment files are PDF file and Excel file on my side.

 

The flow works successfully as below:13.JPG

14.JPG

 

 

The error message told that the $content property could not detected using the 'body('Get_attachment_content')?['$content']' within your "Append to array variable" action. I have made a test on my side, if the attachment file is a .txt file, the error would show up as you mentioned.

 

Please check if the Attachment files of the new created item contain .txt file, if the Attachment files contain .txt file, the result the 'body('Get_attachment_content')?['$content']' expression returned doesn't contain the $content property.

 

 

Best regards,

Kris

 

 

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

BigE
Level: Powered On

Re: Flow no longer working - Property selection is not supported on values of type 'String'

So yeah, I tested with an image just now and the Flow ran as expected. It seems to just fail when a .txt file is attached. I wonder what the limitation is in regards to attaching a text file?

mahesh_mohan
Level: Powered On

Re: Flow no longer working - Property selection is not supported on values of type 'String'

Is there any solution for this issue? Even i am also having the same issue.

Helpful resources

Announcements
thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

firstImage

Incoming: New and improved badges!

We've given our badges an overhaul and also added some brand new ones!

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

sixthImage

Power Platform World Tour

Find out where you can attend!

seventhimage

Webinars & Video Gallery

Watch & learn from the Power Automate Community Video Gallery!

Top Kudoed Authors (Last 30 Days)
Users online (5,031)