当我尝试根据此链接Google MAP将 Google 地图添加到 ios6 时
我获得了 API KEY 并将其放入我的应用程序中,但它崩溃了,原因是“Google MAP SDK for ios 必须通过 [GMSServices ProvideAPIKey:...] 进行初始化”
任何人都可以帮助我,给我视频如何做任何事情......
#import "AppDelegate.h"
#import <GoogleMaps/GoogleMaps.h>
#import "ViewController.h"
@implementation AppDelegate
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
// Override point for customization after application launch.
self.viewController = [[ViewController alloc] initWithNibName:@"ViewController" bundle:nil];
self.window.rootViewController = self.viewController;
[self.window makeKeyAndVisible];
return YES;
[GMSServices provideAPIKey:@"AIzaSyBoOGGGQnvDydbKcxGeB1of6wu2ibE6Rjk"];
}