Is it possible to show multiple pins and direction for each points in MKMapView - iphone

Is it possible to show directions from one point to another point recursively until i reach the destination from source point like Route or Path from Source to Destination in iPhone using MKMapVIew.
I tried with MKOverlayPath and MKpolyline but not able to proceed.
Please help me in this issue?

hello hope this will help you..
download this demo with this you can find the direction of the 2 position in map view and than you can use timer for updating its location after each second so its seems like what you want..

Related

iOS 7 MKMapView Does not provide a route between two points

Hi there am using the Map Kit, i did add several points based on Lat & long Data, so far, it's all good. I Did try to implement the MKDirections methods but i get this response: A route to the destination from its nearest road cannot be determined, NSLocalizedDescription=Directions Not Available, MKDirectionsErrorCode=7, MKErrorGEOError=-403
My question is: If i somehow own the data of those routes between two points, is there a way to draw the route using the MapKit instead of asking apple to provide a route?
thanks in advance for your responses
Yes, you can draw a polyline, if you know the sequence of lat,lon coordinates along the road from start to destination.
Apples BreadCrumbs demo code shows how to do that.

MKMapView display route

Im pretty new to mkmapview so I'll hope my question will be clear enough.
Let's say I have a code where im saving the userLocation in an array (MKuserLocation type). im saving this for every step the user take and than I want to display this.
How do I do that? how can I use this userlocation with the coordinates that I save and display the path?
* im adding this after the comment I was told to use MKmapoverlay. does someone can give me an example how to use this with coordinates? or have some guide (I really tried something clear enough on google but didn't)
Thanks
yes, you can make a path from thoses point. You must be careful to to have your array of point in the right order otherwise you will draw lines between point in every direction. you can draw a line with an mkoverlay
I have faced same issue few days ago and I found the sample application on GitHub.you can download the project from here.
I hope it will be helpful !!

Tile Overlays in iPhone App

There is a webpage I am looking at that displays a Google Map (via javascript), but certain areas of the map have an overlay (textures appear different than the rest of the map, etc.). From what I can gather, this is done on the webpage via a getTileURL function, which depends on the zoom level and current coordinate.
I am interested in portraying this same overlay in my iPhone application, which currently has a mapView set up. Is there anyway to implement the same sort of getTile function in objective-c for a mapView?
If someone could please provide some sample code or point me in the right direction I would greatly appreciate it. Thank you.

Putting GPS current location and pin annotations on a UIImageView

I am making an iPhone app for a local college. I am currently trying to take a drawn map of the campus and put pin annotations on it. I also want to be able to show the users current location on this map image. Right now I just have a UIImageView inside of a UIScrollView. It can currently scroll and zoom in/out. How would I go about accomplishing this? I have searched everywhere for an answer and can't seem to find a solution (or have overlooked it). Am I going in the right direction? Thanks for your help.
You would have to come up with a function to translate latitude and longitude into pixel offsets in the image. Assuming the campus is relatively small compared to the Earth (so you can ignore the planet's curvature), this should be a simple matter of determining the coordinates of the four corners of the image and interpolating.

iPhone zoom map to show all pins

I've just found this for doing this on the Android but has anyone got this to work on the iPhone?
What I'm looking for is a method that will zoom the map to show all pins that are showing...
Thanks
I'm not sure if there's a built in method, but the usual way is to loop through your annotations, looking at their coordinates, and find the maximum and minimum latitudes and longitudes. You'll end up with 4 numbers, you can create a region from them and set the map to that region.
Here is the solution! :)
http://sdhillon.com/find-the-center-and-span-of-a-set-of-points-android-and-iphone-example/