Open the Maps app and display the specified map items.
- iOS 6.0+
- macOS 10.9+
- watchOS 2.0+
An array containing one or more
MKMapobjects representing the items you want to display on the map.
Additional information that the Maps app can use to configure the map display. For example, you can use the launch options to specify the visible map region, a 3D perspective, and the map type. For a list of keys you can put into this dictionary, see Launch Options Dictionary Keys.
You may specify
nilfor this parameter.
YES if the map items were successfully opened by the Maps app, or
NO if there was an error.
You use this method to pass one or more map items to the Maps app. For example, you might use this method to ask the Maps app to display location-based search results generated by your app. Maps displays pins at each location you specify and uses the contents of each map item object to display additional information.
If you specify the
MKLaunch option in the
launch dictionary, the
map array must have no more than two items in it. If the array contains one item, the Maps app generates directions from the user’s current location to the location specified by the map item. If the array contains two items, the Maps app generates directions from the location of the first item to the location of the second item in the array.
If you do not include the
MKLaunch keys in your
launch dictionary, Maps constructs a region that encompasses the provided items. It uses this region to set the visible portion of the map.