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 / Flow expression to lim...
Power Automate
Answered

Flow expression to limit number of characters pulled from List column

(0) ShareShare
ReportReport
Posted on by 25

Hello,

 

I have a flow that generates an email and displays certain information from select columns in a SharePoint list. The Notes column has quite a bit of text and we want to limit the number of characters that are displayed, e.g. the email would show only the first 500 characters from the Notes field.

 

I've looked online but can't find an example of an expression. I'm also new to this so am struggling trying to figure out the exact language.

 

Can someone help?

 

Thanks.

 

 

 

Categories:
I have the same question (0)
  • Ellis Karim Profile Picture
    11,816 Super User 2026 Season 1 on at

    Hi @Elevis 

     

    You can use the substring function: Reference guide for expression functions - Azure Logic Apps | Microsoft Learn

     

    For example:

    Snag_262fdaa7.png

     

    ekarim2020_0-1707860430265.png

     

    You can check the length of the string output by the substring function using the length() function:

    Snag_2631be5b.png

     

    "The sun dipped below the horizon, casting a warm orange glow across the tranquil countryside. As the daylight faded, the nocturnal creatures began to stir, their presence felt in the rustle of leaves and the distant hoot of an owl. In the village below, lights flickered on one by one, illuminating the winding streets and quaint cottages. The scent of wood smoke wafted through the air, mingling with the earthy fragrance of damp soil. In the distance, a lone figure made their way along a dirt trac"

     

    Snag_263490d4.png


    Ellis
    ____________________________________
    If I have answered your question, please mark the post as ☑️ Solved.
    If you like my response, please give it a Thumbs Up.
    My Blog Site

  • Elevis Profile Picture
    25 on at

    Thanks. Let me know if I'm oversimplifying this. Here's the setup I have. If the Notes field has been changed, the email is generated. Can I add an expression to the email body to get the same result?

     

    Elevis_0-1707862950880.png

    Rick

  • Verified answer
    Ellis Karim Profile Picture
    11,816 Super User 2026 Season 1 on at

    Hi @Elevis ,

     

    Yes, you can enter the expression directly into the email Body:

     

    2024-02-13_22-49-35.gif

     


    Ellis
    ____________________________________
    If I have answered your question, please mark the post as ☑️ Solved.
    If you like my response, please give it a Thumbs Up.
    My Blog Site

  • Elevis Profile Picture
    25 on at

    Hi @ekarim2020,

     

    Thanks for the help, I really appreciate it. I got it to generally work but there are some odd things happening. 

    First, it's returning only about half of the 500 characters - around 235 when the limit is 500 and 267 when I upped the limit to 1,000. Also, in a few instances it cut the characters short and returned formatting code. Here's an example:

     

    "2/14/24 - This is a test. This is a test. <span style="font-family:Calibri, Arial, Helvetica, sans-serif;background-color:rgb(255, 255, 255);display:inline !import". 

     

    We're using Enhanced Rich Text in the column so I'm thinking that is "throwing it off".  I did a test and created a Notes2 column with only plain text and that returned 500 characters. So the Enhanced Rich Text is probably the culprit.

     

    Is there any to tweak the expression to use Enhanced Rich Text and avoid the issues I outlined? Or is this just one of the "drawbacks" of using Enhanced Rich Text?

     

    Rick

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