Tag: uwp maps

MapLocationFinderResult上的凭证无效uwp c#

我使用MapLocationFinder时遇到了一个奇怪的问题。 我正在使用MapLocationFinder根据字符串地址检索经度和纬度: string address = “”; // Any address here var locFinderResult = await MapLocationFinder.FindLocationsAsync(address, new Geopoint(new BasicGeoposition())); 在此之后,我使用Laucher启动“驱动器”应用程序并获取导航地图: var geoPos = locFinderResult.Locations[0].Point.Position; var url = $”ms-drive-to:?destination.latitude={geoPos.Latitude.ToString(CultureInfo.InvariantCulture)}&destination.longitude={geoPos.Longitude.ToString(CultureInfo.InvariantCulture)}&destination.name={address}”; var driveToUri = new Uri(url); await Launcher.LaunchUriAsync(driveToUri); 直到最近,这在所有设备上都运行良好。 我不需要任何令牌或任何东西,因为我没有在XAML中实现Map控件。 但是,几天前我开始收到locFinderResult的“InvalidCredentials”响应。 它仍然只适用于一台设备。 我从来没有使用任何凭证,所以我不知道为什么它只适用于这个。 有谁知道什么可能导致这个问题?