cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Brokian42
New Member

Remove a carriage return

Hi,

I am using the following to extract data from an email as a variable to then populate an Excel Spreadsheet,  all is working fine but it appears that a carriage return is added in the Excel Spreadsheet, is there a way to trim that data?

 

first(skip(split(body('Html_to_text'),'Engineer: '),1))

 

 

11 REPLIES 11
StalinPonnusamy
Super User
Super User

Hi @Brokian42 

 

 

uriComponentToString(replace(uriComponent(body('Html_to_text')), '%0A', ''))

 

or

replace((body('Html_to_text'),decodeUriComponent('%0A'),'')

 

Please share the sample content for the HTML text to help further. 


Thanks,
Stalin - Learn To Illuminate

 

StalinPonnusamy
Super User
Super User

Hi @Brokian42 

 

I was referring to the new line (Line feed) char from W3Schools

 

StalinPonnusamy_0-1637854186354.png

 

 

CNT
Super User
Super User

@Brokian42 Try this,

Substitute(yourText, Char(13), "")

So would that be something like

 

Substitue(first(skip(split(body('Html_to_text'),'Engineer: '),1)),Char(13),"")

@Brokian42 Yes!

Brokian42
New Member

Sadly get an error message that the Expression is invalid

@Brokian42 Make sure first(skip(split(body('Html_to_text'),'Engineer: '),1))  is returning a Text.

@CNT I copied the solution from elsewhere as am new to Automate,  does the following help?

Brokian42_0-1638176630405.png

 

StalinPonnusamy
Super User
Super User

Hi @Brokian42

 

  1. Did you try my solution?
  2. Provide sample text that you are trying to do? It helps us to find solutions easily.


Thanks,
Stalin - Learn To Illuminate

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

Carousel_PP_768x460_Wave2 (1).png

2022 Release Wave 2 Plan

Power Platform release plan for the 2022 release wave 2 describes all new features releasing from October 2022 through March 2023.

365 EduCon 768x460.png

Microsoft 365 EduCon

Join us for two optional days of workshops and a 3-day conference, you can choose from over 130 sessions in multiple tracks and 25 workshops.

Top Solution Authors
Users online (3,220)