Skip to main content

Notifications

Power Automate - Building Flows
Answered

Replacing /r/n using uricomponent causing an error

(0) ShareShare
ReportReport
Posted on by 122

Hi all,

 

 I need to split csv that contains /r/n but I'm not able to do so

 

I found workaround converting csv to using uriComponent, but it fails with 

 

The template language function 'uriComponent' was invoked with invalid parameters. The parameter at index '0' cannot be converted to URI component.'.

 

 

1) What I do is take attachment and convert it to string - OK output as expected

2) as it is semicolon separated I replace it with comma - not necessary, but it works fine and does everything as expected

3) just covert to uri - fails 

 

Any idea why or other way how to split csv on /r/n?

Thank you!

2021-02-20 15_44_53-Clipboard.png

  • eliotcole Profile Picture
    eliotcole 4,196 on at
    Replacing /r/n using uricomponent causing an error
    For anyone wishing to stay on this site, you can use the following to represent what json would show as '\r\n' in a string value:
    decodeUriComponent('%0D%0A')
  • Verified answer
    Paulie78 Profile Picture
    Paulie78 8,407 on at
    Re: Replacing /r/n using uricomponent causing an error

    Check out the uriComponent expressions on this page I wrote. It has the code you need:

    https://www.tachytelic.net/2021/02/power-automate-parse-csv-file-json/

     

    Let me know if it works for you.

     

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

Microsoft Kickstarter Events…

Register for Microsoft Kickstarter Events…

Announcing Our 2025 Season 1 Super Users!

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

Announcing Forum Attachment Improvements!

We're excited to announce that attachments for replies in forums and improved…

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 145,343

#2
RandyHayes Profile Picture

RandyHayes 76,287

#3
Pstork1 Profile Picture

Pstork1 64,703

Leaderboard