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 Apps / Bing Maps connector : ...
Power Apps
Unanswered

Bing Maps connector : Transit option

(1) ShareShare
ReportReport
Posted on by 4

I'm using the Bing Maps connector for calculating travel distances and travel duration, for the default 'Driving' travelMode it works fine, but for the 'Transit' travelMode I just can't get it to work.

I'm not sure what the cause is, but it might be the dateTime property, which is required when using 'Transit' travelMode.

 

I use now something like this :

 

Set(
dist_ov,
BingMaps.GetRoute(
Gallery2_1.Selected.persoon.'Primair adres: Straat' & " " & Gallery2_1.Selected.persoon.'Primair adres: Plaats',
Gallery1_1.Selected.crmrow_accountid.address2_line1 & " " & Gallery1_1.Selected.crmrow_accountid.address2_city,{travelMode:"Transit",dateTime:DateTimeValue("10/11/2020 1:50:24.765 PM","nl"),timeType:"Arrival"}
)
);
 
Which results in a request as this :
 
{
"method": "POST",
"headers": {
"x-ms-user-agent": "PowerApps/3.19123.15 (Web AuthoringTool; AppName=xxxxxxxxxxxxxxxxxxxxxxxx)",
"x-ms-client-session-id": "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
"x-ms-client-request-id": "xxxxxxxxxxxxxxxxxxxxxxxxxxx",
"Accept-Language": "en-US",
"Accept": "*/*",
"Cache-Control": "no-cache, no-store",
"x-ms-request-method": "GET",
"x-ms-request-url": "/apim/bingmaps/xxxxxxxxxxxxxxxxxxxxxx/REST/V1/Routes/Driving?wp.0=Achter+de+Carmel+NIJMEGEN&wp.1=Griffioenlaan+UTRECHT&travelMode=Transit&dateTime=10%2F11%2F2020+1%3A50+PM&timeType=Arrival"
}
}
 
Anyone any ideas ?
Categories:
I have the same question (0)
  • v-siky-msft Profile Picture
    on at

    @robdriessen 

     

    The seconds in DateTimeValue function is not supported as a decimal. Please try this:

     

    Set(
    dist_ov,
    BingMaps.GetRoute(
    Gallery2_1.Selected.persoon.'Primair adres: Straat' & " " & Gallery2_1.Selected.persoon.'Primair adres: Plaats',
    Gallery1_1.Selected.crmrow_accountid.address2_line1 & " " & Gallery1_1.Selected.crmrow_accountid.address2_city,{travelMode:"Transit",dateTime:DateTimeValue("10/11/2020 1:50:24 PM","nl"),timeType:"Arrival"}
    )
    );
    Sik
  • Rob Driessen Profile Picture
    4 on at

    @v-siky-msft 

    Thanks for your reply, but makes no difference, still have the same problem, I get the same travel duration for the transit option as I get for the (default) driving option.

  • LowCodeV_R Profile Picture
    15 on at

    Did anyone find a solution for this issue?

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 Apps

#1
WarrenBelz Profile Picture

WarrenBelz 793 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 333 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard