how can i integrate google maps API for my iPhone application? - iphone

I want to use Google Maps on my iPhone application.
I am finding it difficult to get the xml parser code for it though.

The SDK includes the MapKit framework. See this google tutorial to get started.

Add the mapKit Framework to your framework folder.
In your viewController.h file add code:-
#import <MapKit/MapKit.h>
In your viewController.m file:-
[UIApplication sharedApplication openURL:[[NSURL alloc] initWithString: #"http://maps.google.com/maps?q=London"]]

Related

Facebook SDK Swift doesn't code hint while Parse's SDK does

something strange going on, I want to interact with the Facebook and Parse SDK in Swift, so I installed both trough cocoapods pre. I created one Bridge-Header.h file, with these contenst:
#ifndef Pawky_Bridge_Header_h
#define Pawky_Bridge_Header_h
#import <FacebookSDK/FacebookSDK.h>
#import <Parse/Parse.h>
#endif
After that I went to my build settings and pointed my Objective-C bridging header under code generation to this file. It finds them both because if I would append any character to FacebookSDK it won't build (FacebookSDK/FacebookSDKs.h for instance throws an error). And I get parse code hinting in my code, I can work with the SDK but I don't get anything for Facebook.. So Parse is working but I can't get Facebook to work. I already tried downloading the SDK manually and importing it but the same problem...
Someone a clue?
Thanks

Swift: No such module "GoogleMaps" error

I'm trying to use Google Maps SDK for iOS in Swift. I have been following these steps from google developers website. The problem is when I tried to import GoogleMaps in AppDelegate.swift, it's showing an error like..No such module 'GoogleMaps'.
I have added all the frameworks and made necessary changes to Linking and Build settings. Is there anything I'm missing out?
The steps on that website are still for Objective-C apps. To write an app in Swift with the Google Maps API, you need to add a bridging header, and then you can import the module in that header using #import <GoogleMaps/GoogleMaps.h>.
In application:didFinishLaunchingWithOptions: instead of using [GMSServices provideAPIKey:#"API_KEY"]; then you use GMSServices.provideAPIKey("API_KEY").
Delete your all of your pod files including workspace except podinstall and lock and install pod again

iOS 5 twitter usage

I have a full fledged iPhone application already developed for iOS 5 onwards. I have used a third party library for twitter integration. But it always keeps running into a problem for some reason or the other. How feasible is it to replace all that 3rd party stuff by iOS 5 native twitter functionality?
In order to implement twitter integration you have to import the Social framework on your project and also import it in your .h file
#import <Social/Social.h>
Then you have to add these lines of code on the method where you want to make a tweet.
SLComposeViewController *tweetVC = [SLComposeViewController composeViewControllerForServiceType:SLServiceTypeTwitter];
[tweetVC setInitialText:#"My tweet!"];
[self presentViewController:tweetVC animated:YES completion:nil];

iPhone twitter integration: NSXMLParserDelegate protocol not found error

Im very new to iPhone programming, and am facing this really weird issue with importing the Twitter+OAuth libraries for implementing some basic twitter integration into my program.
My SDK is iPhone 3.1.3. After i drag-drop the twitter+oauth library, i add the header path and the library search path
[$(SDKROOT)\usr...whatever as i found in this tutorial ]
I then added the libxml2.dylib framework to the project. When i compile the project, i get six errors, all the same from different .h files that say
"NSXMLParserDelegate protocol not found".
Please help! :(
From the documentation of NSXMLParserDelegate
Available in iOS 4.0 and later.
It simply wont work if you are using SDK 3.1.3
See this question for further info

duplicate symbol _OBJC_METACLASS_$_SBJSON when using CloudMade and Facebook iOs SDKs

I'm trying to compile a project that uses both CloudMade and Facebook.
The Facebook SDK also includes the SBJson library so I get a link error:
duplicate symbol _OBJC_METACLASS_$_SBJSON in ../CloudMadeApi/libs/CloudMade/libCloudMadeApi.a(SBJSON.o) and (...)/Objects-normal/i386/SBJSON.o
If I exclude the Facebook SBJson .m files from the build it compiles but then the SBJson methods are not found at run time.
I'm using the latest CloudMade and Facebook SDKs.
Can someone please help me?
Thanks.
this issue will be fixed soon by removing SBJSON from CloudMade iPhone and iPad SDK. Here is forum post about it: http://support.cloudmade.com/forums/iphone-sdk/posts/1399/show