Text Functions in a Flow | Power Automate

As I was looking at some String/Text operations in Flow recently, here’s what I discovered.

Looks like there are a lot more to come, so let’s look at some initial ones.


Find text position

A pretty simple feature to find the position the Search Text starts from in a String.

Here, I’m trying to find where does ‘yes’ in string ‘Priyesh’ starts from in the given text. And the answer was 3. [Text Index starting from 0]

If the text doesn’t exist, the result is -1


Here’s another important Text function called Substring.

This will return the substring with starting index of 3 and the length of the string from the starting character.

In this case, it’ll return the string “yes”

If your Starting Position in Substring is out of the range i.e. exceeding the length of the entire string, you’ll see and error like below stating the issue.
Also, the same error will be displayed if the Length of the Substring chosen falls out of range i.e. the index exceeding end of the string.

Here are some more Power Automate / Flow posts you might want to look at

  1. Loop through array of objects in a Flow & Create records in CDS | Power Automate
  2. Get Count of records retrieved in CDS connector in a Flow | Power Automate
  3. Number Formatting in a Flow | Power Automate
  4. Call a Dynamics 365 Action from Flow [Bound and Unbound Actions] | Power Automate
  5. Switch-Case in a Flow | Power Automate
  6. Setting Retry Policy for an HTTP request in a Flow | Power Automate
  7. Using Parse JSON to read individual List Records in Flow|Power Automate
  8. Make HTTP request from Flow in Power Automate
  9. Enable Flow button on D365 Ribbon
  10. Button Flow in Power Automate to replicate a Quick Create Form in D365 CE


One thought on “Text Functions in a Flow | Power Automate

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.