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

Community site session details

Session Id : w7Pl037MPxmWxWxlBR/Gid
Power Automate - Building Flows
Unanswered

Extract from .txt attachment to Teams Notification

Like (0) ShareShare
ReportReport
Posted on 21 Apr 2023 21:24:34 by 15

Hello all,

 

I'm looking for a specific solution, and I don't even know where to start. I don't know if a standard PowerAutomate would do, or if I would need an Ai Builder for this task. Anyway below is what  the flow should do

 

1 - When an email arrives to a specific folder matching a specific string on the subject (Trigger)

2 - Read the .txt attachment in the email

3 - Look for a specific string in the .txt file.

4 - On finding this specific string, send a Team's alert including text from lines above and below it.

 

Any hints are appreciated. 

  • Nived_Nambiar Profile Picture
    17,954 Super User 2025 Season 2 on 22 Apr 2023 at 05:43:46
    Re: Extract from .txt attachment to Teams Notification

    Hi @Digzol 

     

    Give a try this way.

     

    Lets's say you have a text file attached with email with content like below

    Nived_Nambiar_0-1682141996469.png

     

    You need to check text file contains Teams Alert  or not and sent notification to team with file content.

     

    Flow used for this

     

    Nived_Nambiar_1-1682142087508.png

     

    Nived_Nambiar_2-1682142109465.png

     

    expression:  base64ToString(items('Apply_to_each')?['contentBytes'])

     

    If the condition is True,

     

    then post a message in ms teams with file content

     

    Nived_Nambiar_3-1682142165670.png

     

    expression used in body: base64ToString(items('Apply_to_each')?['contentBytes'])

     

    Output from flow

    Bot send message to teams

    Nived_Nambiar_4-1682142207840.png

     

     

    Hope this helps 

    Mark it as solution if it resolves your query 🙂

     

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

Announcing our 2025 Season 2 Super Users!

A new season of Super Users has arrived, and we are so grateful for…

Paul Stork – Community Spotlight

We are honored to recognize Paul Stork as our July 2025 Community…

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 497 Super User 2025 Season 2

#2
David_MA Profile Picture

David_MA 436 Super User 2025 Season 2

#3
Riyaz_riz11 Profile Picture

Riyaz_riz11 244 Super User 2025 Season 2

Loading complete