Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Automate - Building Flows
Answered

Remove spaces from string

(1) ShareShare
ReportReport
Posted on by 32

Hi everyone,

 

I am trying to build a flow and I'd like to remove spaces from a string. It works for me in other flows and I use the same formula in Power Automate. 

 

I've got an example where the surname is divided by a space. 

TimBroeren_1-1720426893384.png

I use the following formula in the Compose action. replace(body('output_surname'),' ',''). What I expect to see is that "Sur Name" becomes "SurName". When the testflow has run, I check the input if the example above is expected. But the input value is already "SurName". While in fact it's not. When the following action is to add a row to Excel. The surname-value gives "Sur Name". 

TimBroeren_2-1720427005597.png

 

Can you guys help? Why is the input "SurName", while it's in fact "Sur Name".

 

I look forward to your replies.

 

 

 

  • Verified answer
    TimBroeren Profile Picture
    32 on at
    Re: Remove spaces from string

    I created a variable first and after I created this variable I composed this variable. My problem is solved.

  • TimBroeren Profile Picture
    32 on at
    Re: Remove spaces from string

    @CFernandes It's a response from a MS Forms and it's a direct output from this Form.

  • CFernandes Profile Picture
    8,295 Most Valuable Professional on at
    Re: Remove spaces from string

    @TimBroeren - Is the response from a MS Forms? and are you trying to remove the space from output of ParseJSON output. As you mentioned something it is working in another Flow instance, so something might be different. 

     

    If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

     

    P.S. take a look at my blog here and like & subscribe to my YouTube Channel thanks.

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

Michael Gernaey – Community Spotlight

We are honored to recognize Michael Gernaey as our June 2025 Community…

Congratulations to the May Top 10 Community Leaders!

These are the community rock stars!

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

Leaderboard >