All the sudden, the CLLocationManager won't start on the simulator - I observed this by finding out that the gps icon does show up on the status bar, and also no callbacks to the didUpdateToLocation delegate. What could be the reason causing this?
Add one GPX file in Xcode and in it specify Latitude and Longitude...:)
for example wpt lat="23.04472" lon="72.56839"
Did you change your simulator to version below 5.0? Because simulator version below 5.0 won't support Location Services. Also in simulator in settings make sure Location Services are enabled.
Related
I have a tab based app that uses four tabs. The home tab is an MKMapView. When I load the app onto my iPhone and run from "Xcode" or "Instruments" there are no problems with crashing. However when I load the app onto my iPhone from iTunes or testflight.com it crashes whenever the MKMapView pans or zooms. Everything else in the app seems to work fine.
can you check the iOS version of simulator and device both? this might be happening due to some method or something else which might be not exist in the running version of iOS and your code might be calling that particular method.
You should debug your code while running on device and track the specific action as your were saying crashed happens when only the pan or zooming of mapview performed.
I was working with XCode 4.3 and having a working code. But after upgrading to 4.4 i met with a problem. The problem is that current user location is not being showed on the iphone simulator. I mean the blue dot. And also my pins dissappeared and map is not focusing to the area i wanted. Do u have any idea about this problem?
Did you try this
self.mapView.showsUserLocation=YES;
GPS services doesn't work well in simulator. Apple has supported it in simulator 5 but not in the prior versions.
Make sure you have the Edit Scheme... > Run > Options the 'Allow Location Simulation' checked.
I also had the issue at first. Pin was there but no map displayed, only a grid.
I played with the map to move it around and it start working.
I have xcode 7.3.1
i am developing an application for iphone using iOS 4.2 SDK.
My application need to popup an alert when a user arrives a specific location (in 400m radius). Note that I need to get this alert even if the app is in the background.
When I use the locationManager with startUpdatingLocation mode, i get the alert when the app is in the foreground, but not when it is in the background.
When I try to run with locationManager with startMonitoringSignificantChanges mode, i don't get any position changes in background and even not in foreground (i.e. didUpdateLocation method is never called. only once in the application start up)
some facts:
1. I updated info.plist with UIBackgroundMode with 'location' as first item in array.
2. I updated info.plist UIDeviceCapabilities with gps and location-services (though it doesn't really matters)
3. all said above refers to running this app on the 3GS iphone device.
4. I tried this app on sdk 4.0 and 4.1 and got the same problem.
5. The device supports startMonitoringSignificantChanges use (method of locationManager confirms it)
6. When I check the app on the device i move in range of ~150 meters meters. Is the startMonitoringSignificantChanges will call didUpdateLocation method with this kind of movement?
7. All settings on the devices are turned to on mode (roaming, 3G, wifi,...)
Am i missing something? any ideas?
Thanks,
if you're still interested, have a look at that post:
Behaviour for significant change location API when terminated/suspended?
and the example project mentioned:
http://www.cannonade.net/blog.php?id=1480
Here is a list of problems I have after building my app with xcode 3.2.3 and running it on simulator 4.0.
Of course, all these issues did work with the previous environment.
Location manager does not update location. It used to update with the location at Cupertino but now I get locationManager:didFailWithError: called with error 0.
I have a map view and the panning doesn't work. Moving the map around nor the pinching gesture.
When I click and hold on the map my app, sometimes, crashes and the Log says something about long touch.
Thanks,
Tzur.
The simulator no longer returns a faked location but tries to use your Mac's Airport to locate you. Do you have Airport activated?
I have a UIToolbar at the bottom of the view. when I run the application using iPhone Simulator 2.2.1, the toolbar is displayed in place. But when I run the application using iPhone Simulator 3.0 the toolbar is shifted up from its place. Is there any way I can fix this ? I would appreciate any help.
Thanks,
Sarah
Using toolbars in iPhone OS 2.x is hard to get it right. The documentation is fuzzy, or non-existing. The addition of proper toolbar handling in iPhone OS 3.0 is a clear sign of Apple admitting that toolbars in 2.x where just not ready for the public.
This is not the answer you expect, but the answer you need. Ask yourself; "Will a user who has not bothered to update to iPhone OS 3.0 bother to install my app?"
The answer is most probably no.
Then what you should do is make sure your application uses a UINavigationController, and have each UIViewController that needs a toolbar set it's toolbarItems property to an NSArray with the UIBarButtonItem objects you need.
On iPhone OS 3.0 this will result in a toolbar that is automatically populated, laid out, and managed for you with no fuzz.
What does it look like on the device?
I've had wonky issues with the 2.2.1 simulator since updating to the 3.0 SDK, and from what I've found on Google, I'm not the only one. If it looks fine on the device, then ignore the simulator issues, or debug with the 3.0 simulator instead.