Add GPX File to Xcode 6 Project

自作多情 提交于 2019-12-01 09:58:07

问题


I am following the Trax app demo from Stanford's iOS lectures and the instructor set the app up to handle GPX files via AirDrop, but the iPhone simulator doesn't support AirDrop.

Is there anyway to add files (more specifically GPX files) to an app on the iPhone simulator? I thought about emailing it to myself and using Safari on the simulator, but I have no idea where that would be stored or how to access it from the Trax app.


回答1:


You can add a GPX file to a project by opening the scheme editor: Product -> Scheme -> Edit Scheme. Under Options check the Allow Location Simulation box and from the dropdown choose Add GPX File to Workspace.

In order to generate a GPX file with your custom location you can use this.




回答2:


The way Hegarty does it is he runs the app on his phone (when connected and registered your phone will be the first scheme on the list). Then airdrop on the Mac will see your phone and you're app will grab it.



来源:https://stackoverflow.com/questions/29544344/add-gpx-file-to-xcode-6-project

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!