How to open maps App programmatically with coordinates in swift?

前端 未结 9 2305
忘了有多久
忘了有多久 2020-11-30 18:40

I have latitude and longitude that I want to open into my map application. I tried this code from HERE.

    func goToMap(){

    var lat1 : NSString = self.v         


        
9条回答
  •  暖寄归人
    2020-11-30 19:20

    I know all answers are complete but here I got an answer which is easier to copy paste & also gives the user options to routing with Apple Maps, Google Map & Waze.

    Working with Swift 5+

    https://stackoverflow.com/a/60930491/6449292

    Might help someone...

提交回复
热议问题