Maps and Location

RSS for tag

Build maps and location awareness capabilities into your apps.

Posts under Maps and Location tag

83 Posts
Sort by:
Post not yet marked as solved
0 Replies
158 Views
Hi, We are developing an application for directory syndication. We are looking to integrating with many services like google my business, yelp, foursquare, apple maps etc. It seems like there are no publicly documented APIs for apple maps. But some alternative products in the market like yext, uberall etc does seem to have an integration. Can someone please point me in the right direction to achieve this? Thanks in advance.
Posted Last updated
.
Post not yet marked as solved
0 Replies
154 Views
Hi All, I am trying to implement Alternate Routes using Mapkit in Swift. I am able to get the alternate route details but unable to handle the alternate route selection and drawing the polyline for the selected route. Can someone help me in achieving this some sample code snippet or references? Thanks in advance.
Posted Last updated
.
Post not yet marked as solved
0 Replies
196 Views
I want to see all the public transport stations on my MKMapView. With the following code I get train stations on the map: mapView.pointOfInterestFilter = MKPointOfInterestFilter(including: [.publicTransport]) But the bus stops are missing. If I use the Apple Maps app and chose Transit as the map, the bus stops are available there. How can I get the bus stops in my app using MKMapView?
Posted
by andre07.
Last updated
.
Post not yet marked as solved
0 Replies
718 Views
Hi guys, I have built a PWA that calls the javascript API navigator.geolocation.getCurrentPosition which prompts the user for location access when the Safari permission is set to Ask. This is the correct behavior and works as expected when open in Safari. However when added to the Home Screen and running with a display mode of "standalone", the location alert does not open on my phone (iPhone 13 mini / iOS 15.1.1). And the call never times out. Then if I switch from the PWA to Safari the location alert / prompt is suddenly showing in Safari. So it seems that the alert is targeting the wrong "tab". This does not happen if the PWA display mode is "browser" or "mimimal-ui" with either of those it behaves normally. I can only replicate this on my phone (iPhone 13 mini / iOS 15.1.1). I have also tested on various older phones (15.1.1 and 14.7) as well as several emulators and they all behave as expected. It is possible this is a obscure setting on my phone but it does feel a lot like an iOS Safari bug.
Posted Last updated
.
Post not yet marked as solved
0 Replies
255 Views
Our iOS app tracks user location for the purpose of food & beverage order delivery where the user changes location. At the moment, if user kills app or OS kills we are unable to track that user to give them their order. Is it possible to track the users location even if the app is killed? (with their permission and/or until at least their order is delivered to them) If so, can you provide the solution for this in iOS?
Posted
by SpencerCG.
Last updated
.
Post not yet marked as solved
1 Replies
267 Views
My question is how do you get ahold of the current user location title when clicking a button so that it can display the title inside the search bar. I know that by calling locationManager.requestLocation() inside my button it will redirect the user to current location but that is all know how to do. I've tried calling locationManager.location?.description but i had no luck.
Posted
by Chamoy.
Last updated
.
Post not yet marked as solved
1 Replies
276 Views
Hello everyone, I am currently trying to build a CarPlay application with the Charging entitlement. As part of my application I have a List Template which shows different entries and should start navigation to one of them on click on it. Therefore I used the answer of this question: https://developer.apple.com/forums/thread/669838?login=true and implemented following function:     static func launchmap(cpAppScene: CPTemplateApplicationScene, latitude: String, longtitude: String, carplay : Bool = true) {         let urlString: String!         if UIApplication.shared.canOpenURL(URL(string:"comgooglemaps://")!) {             urlString = "comgooglemaps://?&daddr=\(latitude),\(longtitude)&directionsmode=driving"         } else {             urlString = "http://maps.apple.com/?daddr=\(latitude),\(longtitude)&dirflg=d"         }         if let url = URL(string: urlString) {             if (carplay) {                 cpAppScene.open(url, options: nil, completionHandler: { (Void) in print("completed!")})             } else {                 UIApplication.shared.open(url)             }         }     } Now my main concern is: I can't test this functionality in the CarPlay simulator because it comes without safari and Apple Maps as well as I can't install any external apps like Google Maps. Trying to test this functionality in my car leads to it crashing and I am just frustrated on figuring out how to debug it without the simulator allowing us to install external apps and coming without maps. Are there any ideas? Thank you and best regards Dennis
Posted Last updated
.
Post not yet marked as solved
1 Replies
726 Views
Hi,In my app, If app is running in foreground, I need user's current location.But I have doubt regarding messages for privacy authorization which would be shown in prompt and setting screen of APP-In Current implementation We are showing below messages -:NSLocationAlwaysAndWhenInUseUsageDescriptionEnable location services “Only While Using the App” to choose your car upon arrival and return your car via the app at most locations. You can also find nearby locations, gas stations, and places to park. Choose “Always Allow” to further personalize your experience.NSLocationAlwaysUsageDescriptionEnable location services to choose your car upon arrival and return your car via the app at most locations. You can also find nearby Avis locations, gas stations, and places to park.NSLocationWhenInUseUsageDescriptionEnable location services to choose your car upon arrival and return your car via the app at most locations. You can also find nearby Avis locations, gas stations, and places to park.Here the discription for whenInUse and AlwaysAllow is same because in iOS10, prompt will be shown with two buttons allow and don't allow instead of "always allow" and "while in use" button titles and the description of NSLocationAlwaysUsageDescription will be shown in prompt and setting screen.And for iOS11 NSLocationAlwaysAndWhenInUseUsageDescription this message would be shown which is correct because in iOS11 there will be three button "always allow", "while in use" and "never".Is that description is suitable for NSLocationAlwaysUsageDescription for iOS 10or do we need to change the message to specify the description of always allow?Your help would be appreciated.ThanksAmit Gupta
Posted Last updated
.
Post not yet marked as solved
2 Replies
518 Views
I know macOS doesn't allow running multiple instances of an application in normal circumstances. However, for macOS native applications, there is a work around of using -n in the command line. Unfortunately, this option doesn't seem to work for iOS applications running on iOS. Also, I have been having issues with locations services working correctly when running such an instance. For example, if a game requires doing a GPS location check, it does not seem to be able to do it correctly when running the application in macOS, the app doesn't freeze, but it gets stuck and needs to be restarted. I have looked around online and searched around in settings for quite a bit of time with no success. Any ideas?
Posted Last updated
.
Post not yet marked as solved
0 Replies
240 Views
Why locationManager did disconnect in this circumstance? Always after START -> STOP -> START service. locationManager = [[CLLocationManager alloc] init]; locationManager.delegate = self; locationManager.desiredAccuracy = kCLLocationAccuracyBest; locationManager.distanceFilter = 5; // meters locationManager.allowsBackgroundLocationUpdates = YES; locationManager.pausesLocationUpdatesAutomatically = NO; if (@available(iOS 14.0, *)) {     if (locationManager.authorizationStatus == kCLAuthorizationStatusAuthorizedWhenInUse){       [locationManager startUpdatingLocation];     } else {       shouldStart = false; [locationManager requestWhenInUseAuthorization];     }   } else {     // Fallback on earlier versions   } --- resume log --- {"msg":"#sbim client arrow state changed", "clientKey":"it.trainingcamp.app", "entityClass":"Application", "oldArrowState":"ReceivingLocationInformation", "newArrowState":"RequestingLocationInformation", "dueToDeauthorization":0} client 'it.trainingcamp.app' authorized for location; starting shortly client 'it.trainingcamp.app' authorized for location; starting now, desiredAccuracy, -1.0, distanceFilter, 5.0, operatingMode 0, dynamicAccuracyReductionEnabled 0, allowsAlteredAccessoryLocations 0, activityType 0 [application<it.trainingcamp.app>:9023] Suspending task. Calculated state for application<it.trainingcamp.app>: running-suspended (role: None) Process runningboardd.34 Released SystemIsActive "application<it.trainingcamp.app>34-77-203313:Location subscription" age:00:00:31 id:51539648441 [System: SysAct] -CMSessionMgr- CMSessionMgrHandleApplicationStateChange: Client it.trainingcamp.app with pid '9023' is now Background Suspended. Background entitlement: YES ActiveLongFormVideoSession: NO WhitelistedLongFormVideoApp NO -CMSessionMgr- CMSessionMgrHandleApplicationStateChange: Sending stop command to it.trainingcamp.app with pid '9023' because client is background suspended and there is no AirPlay video session for it [application<it.trainingcamp.app>:9023] Setting process task state to: Suspended
Posted Last updated
.
Post not yet marked as solved
1 Replies
654 Views
Hello, I set up multiple Advanced App Clips experiences with some attached to locations in Apple Maps. But it never appears on those locations in the Maps app. However, the App Clips perfectly launch when scanned from a QR Code, but the App Banner in Safari does not appear if the App is not already installed on my phone. Does anyone know how to debug and fix this issue? Or maybe I am missing something, a review of such Advanced App Clips Experiences linked to Maps perhaps?
Posted
by lbtbly.
Last updated
.
Post not yet marked as solved
0 Replies
246 Views
Hi, Our application needs to receive and process positions, even in background. The associated UIBackgroundMode is activated, and everything was working well until I updated a test tablet to 15.3.1. The application was switching to background (with position correctly feeds - as expected), but never to suspended. Now it keeps background mode for few seconds or minutes (GPS working at this moment) and then switches to suspended where no more events are triggered. Is there any recent changes on this subject that could explain ? (that's critical for our application)
Posted
by Jerome.D.
Last updated
.
Post not yet marked as solved
3 Replies
1.5k Views
Hi guys. I just started developing my own apps and I am very new to Swift and development for iOS, but I had an idea for a great app that utilizes the "Look around" feature that Maps provide, but I can't find any information about this in the documentation for MapKit. Does anyone know if it currently possible to enable a view for this? Thanks in advance!
Posted
by Halallica.
Last updated
.
Post not yet marked as solved
2 Replies
395 Views
Hi all, I'm working on an app which requires the most accurate AGPS available, so it requires a device with cellular capabilities even if the network is going over wifi, and even if the cellular modem is turned off. The IP-based location services in a non-cellular device (like a wifi-only iPad or an iPod touch just isn't accurate enough for what I'm doing. I know I can put that in the description in the app store, but I'm wondering if there's a way I can account for it in my code, too. Something like the user interface idiom or iOS version checks you can do, but instead specifically isCellularCapable or some such. I just want it to be clear whenever someone fires up the app with an iPod touch or a non-cellular iPad that they're going to have a less-than-ideal experience. I still remember when my kid's friend tried to do Pokemon Go with a non-cellular iPad tethered to my phone, and the device just couldn't figure out where it was supposed to be. I don't want people using my app to have the same experience.
Posted Last updated
.
Post not yet marked as solved
2 Replies
351 Views
I am currently trying to create a map. However a bunch of errors keep showing up. What I am doing wrong and how would I be able to fix this?
Posted Last updated
.
Post not yet marked as solved
0 Replies
217 Views
I am working on an app that requires location to work in the background constantly. I am using CLLocationManager. Whats happening is after sometime the location service stops working in the background. We have seen the location services stop with in 30 seconds of being in the background, as well as up to 20 hours of location working in the background then it stops. Usually the app doesn't crash, but at times we have seen a crash (very rarely). Currently we: Enabled the background location in info.plist Requests always authorization Start location updates in the foreground allowsBackgroundLocationUpdates is set to true pausesLocationUpdatesAutomatically is set to false. when a car is detected the desired accuracy is set to kCLLocationAccuracyBestForNavigation Any help would be great.
Posted
by Turtle919.
Last updated
.
Post not yet marked as solved
1 Replies
907 Views
since I set the MKUserTrackingMode to follow I get this error : [MKCoreLocationProvider] CLLocationManager(<CLLocationManager: 0x6000003b86d0>) for <MKCoreLocationProvider: 0x6000033b05a0> did fail with error: Error Domain=kCLErrorDomain Code=1 "(null)" and the map doesn't track the location of the gpx file either. What can you do there?
Posted
by cryptos90.
Last updated
.