cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
cyint
Regular Visitor

unable to concat URL & Coordinates value as one URL

Hello,

 

I am building a flow where an adaptive card is posted on teams when a new record is created in SP list.

 

For this purpose I need to make a provision wherein a clickable link is embedded in the adaptive card, clicking on which will take the user to Google Maps with the coordinates as an input.

 

There are 2 parts of the concat expression:

1) This part of the URL: https://www.google.com/maps/search/

2) Coordinates fetched from SP list (xx.xxxxxxxx,xx.xxxxxxxx)

 

I want to concat these together but always there is space appearing:

https://www.google.com/maps/search
2x.5487xxxx,4x.xxxx8473

 This is rendering the link to work partially.

 

Any help would be greatly appreciated.

1 ACCEPTED SOLUTION

Accepted Solutions
cyint
Regular Visitor

So I was able to get it work.

There was a '/r' which I missed to escape, causing the coordinates to move to next line thereby causing the split in URL.

 

This is the code I used: 

uriComponentToString(replace(uriComponent(outputs('Compose_5')), '%0D', ''))

Now the URL is working as it should.

View solution in original post

2 REPLIES 2
PrasadAthalye
Super User
Super User

Can you use Compose and build expression like below? I am using Title field from SP List and Get Items action and that is why apply to each. You can use yours. If you are using just Get Item you don't need apply to each.

 

 

concat('https://www.google.com/maps/search/', items('Apply_to_each')?['Title'])

 

Please Like and Mark this as Answer if it resolves your Issue.

Power Automate Community
cyint
Regular Visitor

So I was able to get it work.

There was a '/r' which I missed to escape, causing the coordinates to move to next line thereby causing the split in URL.

 

This is the code I used: 

uriComponentToString(replace(uriComponent(outputs('Compose_5')), '%0D', ''))

Now the URL is working as it should.

View solution in original post

Helpful resources

Announcements
Process Advisor

Introducing Process Advisor

Check out the new Process Advisor community forum board!

MPA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

V3_PVA CAmpaign Carousel.png

Community Challenge - Giveaways!

Participate in the Power Virtual Agents Community Challenge

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

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

Top Kudoed Authors
Users online (3,153)