2

AppDelegate.m

#import "GAI.h"
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{

    // Optional: automatically send uncaught exceptions to Google Analytics.
    [GAI sharedInstance].trackUncaughtExceptions = YES;
    // Optional: set Google Analytics dispatch interval to e.g. 20 seconds.
    [GAI sharedInstance].dispatchInterval = 20;
    // Optional: set debug to YES for extra debugging information.
    [GAI sharedInstance].debug = YES;
    // Create tracker instance.
    id<GAITracker> tracker = [[GAI sharedInstance] trackerWithTrackingId:@"UA-42949960-2"];

    self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
    self.viewController = [[ViewController alloc] initWithNibName:@"ViewController" bundle:nil];
    self.window.rootViewController = self.viewController;
    [self.window makeKeyAndVisible];


    return YES;
}

ViewController.h

#import "GAITrackedViewController.h"
@interface ViewController : GAITrackedViewController <UIActionSheetDelegate, NSURLConnectionDelegate,NSURLConnectionDataDelegate,NSURLConnectionDownloadDelegate,UIAlertViewDelegate>
{

}

ViewController.m

#import "GAI.h"

-(void)viewDidAppear:(BOOL)animated{
    [super viewDidAppear:animated];
    self.trackedViewName = @"Home Screen";
}

何が悪いのか理解できません。サインに従ってグーグルで検索してください。これが必要なことです。

4

0 に答える 0