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

Problem with condition and SharePoint

Hello people! I'm using a flow for change name in some archives, and I do OCR on the archive and get the infos I want to use, but they should be placed in different folders, so I'm using a condition... The problem is that for some text I get from the OCR it works fine, but for the others, it returns InvalidTemplate contains expect to receive a string... Here is some screenshot from my flow, it is in portuguese, but I think it won't be a problem... 

victor_lion_0-1603894772371.png

I receive the OCR from HTTP, but also tried to use substring function, compose, and others, with no success

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Community Support
Community Support

Hi @victor_lion,

 

It seems that the error is caused by the different data types input in the two sides of Condition action.

If a string on one side of Condition action, an integer on the other side, the condition couldn't work. You should use int() function or string() function to convert one side, for example:

Screenshot 2020-10-29 103817.jpg

 

Best Regards,
Community Support Team _ Lin Tu
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
Highlighted
Community Support
Community Support

Hi @victor_lion,

 

It seems that the error is caused by the different data types input in the two sides of Condition action.

If a string on one side of Condition action, an integer on the other side, the condition couldn't work. You should use int() function or string() function to convert one side, for example:

Screenshot 2020-10-29 103817.jpg

 

Best Regards,
Community Support Team _ Lin Tu
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

Highlighted

Hi @v-litu-msft

 

I'm using string(), and also have used substring, to select just one line of the document:

victor_lion_0-1603969659488.png

This nested flow receives information from this flow:

victor_lion_1-1603969771135.png

But it appears to be random, as some of the files it goes well, and for some of them occurs the related error.

Highlighted

@v-litu-msft, just used string() on both flows, and it came out ok, will do some more tests, and I hope this is it, thanks for the help!

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

Power Platform ISV Studio

Power Platform ISV Studio

ISV Studio is designed to become the go-to Power Platform destination for ISV’s to monitor & manage published applications.

Users online (8,536)