【问题标题】:MapQuest ios API unable to request routeMapQuest ios API 无法请求路由
【发布时间】:2012-11-08 17:10:39
【问题描述】:

我正在尝试在 MQMapView 上绘制路线。我在模拟器中对routeLoadFinished() 回调得到以下响应,

<?xml version="1.0" encoding="UTF-8"?><response>
<info><statusCode>400</statusCode>
<messages><message>No sessionId found in request. You must provide a sessionId when requesting a Route Shape.</message></messages><copyright>    <imageUrl>http://api.mqcdn.com/res/mqlogo.gif</imageUrl><imageAltText>© 2012 MapQuest, Inc.</imageAltText><text>© 2012 MapQuest, Inc.</text></copyright></info><route/></response>

我不知道为什么它说我正在请求一个路线形状,而我只是想通过[self.route getRouteWithStartCoordinate:start endCoordinate:end]; 绘制路线

我正在使用许可数据。

【问题讨论】:

    标签: iphone ios map mapquest


    【解决方案1】:

    您仍然看到此错误吗?通常,状态码 400 表示输入有问题,因此服务无法计算路线。您是否认为您指定的坐标之间可能没有路线(即,如果其中一个在海洋或水体中,或者远离道路网络等)?

    免责声明:我在 MapQuest 工作。

    【讨论】:

    • 这正是我的问题,我的 gpx 文件中定义的坐标无效。更正了坐标,路由现在工作得很好。非常感谢!
    猜你喜欢
    • 2014-06-27
    • 1970-01-01
    • 1970-01-01
    • 2021-01-26
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2015-07-21
    • 2021-04-02
    相关资源
    最近更新 更多