Skip to main content

Notifications

Community site session details

Community site session details

Session Id : qaYTlTNBhiX+Bl9M0xcNLw
Power Automate - General Discussion
Unanswered

Convert a .txt file to a SharePoint list

Like (0) ShareShare
ReportReport
Posted on 3 Aug 2023 09:44:42 by 37

Hello everyone,
I have a txt file. like this,

Immagine 2023-08-03 113905.png

I would like to convert it to a SharePoint list, where the columns correspond to the letters in the .txt file, with Power Automate.

Thank you if anyone can help me

  • SamLed Profile Picture
    2,332 Moderator on 04 Aug 2023 at 11:05:34
    Re: Convert a .txt file to a SharePoint list

    You just have to adapt the way you get file, in article it comes from OneDrive, but you can obviously get a file from mail attachment, a sharepoint library or a folder. How to process the file doesn't change except for field separator which is "|" in your case.

     

    [Edit] you can also deal with file content just before you save it into a folder.

    ______________________________________________________________

    If I have answered your question, please Accept the post as solution.
    If you like my response, please Thumbs Up.

     

  • MatildeBecherel Profile Picture
    37 on 04 Aug 2023 at 10:59:40
    Re: Convert a .txt file to a SharePoint list

    Thanks for the reply but this doesn't work for me because the .txt file comes to me by email and with power automate I download it directly into a folder

  • SamLed Profile Picture
    2,332 Moderator on 03 Aug 2023 at 10:25:51
    Convert a .txt file to a SharePoint list

    Hi,

    Your text file can be treat as CSV file using pipe as separaror char.

     

    Have a look to this article which shows how to consume CSV file and build JSON : https://www.tachytelic.net/2021/02/power-automate-parse-csv/?amp

     

    Just replace coma by pipe in the split line expression.

     

    Then you just have to use Create item action assigning correct value to related field.

     

    You don't have to transform your extrated data to JSON, but it is more readable than array indexes and field will be available in dynamic contents.

    ______________________________________________________________

    If I have answered your question, please Accept the post as solution.
    If you like my response, please Thumbs Up.

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

Understanding Microsoft Agents - Introductory Session

Confused about how agents work across the Microsoft ecosystem? Register today!

Warren Belz – Community Spotlight

We are honored to recognize Warren Belz as our May 2025 Community…

Congratulations to the April Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 146,771 Most Valuable Professional

#2
RandyHayes Profile Picture

RandyHayes 76,287 Super User 2024 Season 1

#3
Pstork1 Profile Picture

Pstork1 66,091 Most Valuable Professional

Leaderboard
Loading started