web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Word Counting (regex) ...
Power Automate
Answered

Word Counting (regex) in PowerAutomate

(0) ShareShare
ReportReport
Posted on by 9

Context :
User input is marked as draft in the associate powerapps until it meets a certain wordcount.

Flow should send out an email reminder to users who's textbox doesn't match the wordcount.

Powerapp formula:

 

 

CountRows(
 Filter(
 MatchAll(
 ThisItem.'Peer comment',
 "(\s|\n?)*(\s|\n?)"
 ),
 !IsBlank(FullMatch)
 )
 )

 

 

 I'd like to count the wordcount the same way in my flow, to make sure the wordcount is consistent across both the app and the flow.

Issue is the functions I use in powerapps don't seem to exist in powerautomate.

I've seen I could use an excel spreadsheet to do the match,but that sounds overly complex.

Any suggestions ?

Categories:
I have the same question (0)
  • grantjenkins Profile Picture
    11,063 Moderator on at

    There are some third-party connectors that offer regex. Otherwise, I'd suggest Office Script as you mentioned if you needed regex.

     

    The only downside with using Office Scripts is that they are stored in your OneDrive. So, if other people need to use the script (flow runs as another user) you will need to share the Office Script first. We can now store Office Scripts in SharePoint, but unfortunately at this stage, you then can't access it from Power Automate - so needs to be in OneDrive for now.

     

    Another alternative is to split the textbox content by " " which should give you an array of words and you can use length to get the number of items (words) in the array.

  • Verified answer
    BrokenClock431 Profile Picture
    9 on at

    I've gone plan B, and added a wordocunt column that the powerapps populates when submitting the form.

    Not exactly great but hey.
    Wish there was feature parity across the power ecosystem for different functions.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Leaderboard > Power Automate

#1
David_MA Profile Picture

David_MA 124 Super User 2026 Season 1

#2
Ellis Karim Profile Picture

Ellis Karim 52 Super User 2026 Season 1

#3
Haque Profile Picture

Haque 50

Last 30 days Overall leaderboard