Reputation: 842
I am trying to send a screen to Google Analytics using its SDK (3.11) on iOS, but nothing is happening on the GA console, even after 24h.
I doubled checked the identifier which look like this UA-xxxxxxx-x.
Here is the code I use to setup the SDK :
in my AppDelegate
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
[GAI sharedInstance].optOut = YES;
[GAI sharedInstance].dispatchInterval = 1;
[GAI sharedInstance].trackUncaughtExceptions = YES;
[[[GAI sharedInstance] logger] setLogLevel:kGAILogLevelVerbose];
[[GAI sharedInstance] trackerWithTrackingId: self.config.googleAnalyticsTrackingId];
return YES;
}
in my ViewController, which inherits from GAITrackedViewController
- (void)viewWillAppear:(BOOL)animated {
[super viewWillAppear:animated];
self.screenName = @"MyControllerScreen";
}
Any idea ?
Upvotes: 0
Views: 166
Reputation: 10475
You have opted out of analytics data tracking..
[GAI sharedInstance].optOut = YES;
Comment for optOut
property clearly states..
When this is true, no tracking information will be gathered; tracking calls will effectively become no-ops.
So either set it to false optOut = NO
, or just comment out that line and try again.
Upvotes: 2