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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Replace two strings in...
Power Automate
Unanswered

Replace two strings in a text at the same time

(1) ShareShare
ReportReport
Posted on by 4
Hi everyone,
 
I have to replace two strings in a text at the same time.
My text is the following:
 
"The scope of the action regards the following task:
yyy
Please access the dedicated digital platform through the following link: XX.com"
 
The yellow words are the ones that I have to replace.
For the value "yyy", I have created a dynamic variable that gets the values from a Dataverse table, and for "xxx" I have to insert a static text.
I have created a replace condition: 
 
replace(
        items('Apply_to_each')?['my text'],
        'yyy',
        variables('varTask')
    ),
)
 
But I don't know how to insert the link.
 
Thank you so much for your suggestions
 
Categories:
I have the same question (0)
  • Suggested answer
    trice602 Profile Picture
    15,402 Super User 2025 Season 2 on at
    Hi,
     
    This can be done with a nested replace, shown below.
     
    replace(
        replace(
            items('Apply_to_each')?['my text'], 
            'yyy', 
            variables('varTask')
        ), 
        'XX.com', 
        'https://your-static-link.com'
    )
     
    In the above example, you would replace XX.com and the link with your dynamic content.

    ------------------------------------------------

     

     

    ⭐ If this was helpful, please like and mark as a verified answer to help others find this too!

     

     

    Always glad to help! 💯💯💯💯💯

     

    Tom

     

    Follow me on LinkedIn - Thomas Rice, PMP | LinkedIn

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 538 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 405 Moderator

#3
abm abm Profile Picture

abm abm 252 Most Valuable Professional

Last 30 days Overall leaderboard