alim91
alim91

Reputation: 546

iOS google analytics implementation error

i have a phone gap iOS application already finished, and i wanted to implement google analytics in it. i have download the GA sdk 3.07, and i follow the steps and everything is ok. on running on device i have an error that no @interface GAITrackerViewController declare the method webviewdidfinshloading, so ia disabled and i run, its run but i don't the web page created, i only see a white screen, i went to google analytics site, the site did track my application. so i replace

@interface MainViewController : GAITrackedViewController
@end

by

@interface MainViewController : CDVViewControler
@end

but i can't track the application. i am beginner in iOS and i need help. thx

Upvotes: 0

Views: 317

Answers (1)

streem
streem

Reputation: 9144

You'll probably need to manage the tracking manually, since your MainViewController must inherit CDVViewController.

In your controller after initializing your tracker you can try something like :

NSDictionary *params = [NSDictionary dictionaryWithObjectsAndKeys:
                        @"appview", kGAIHitType, @"Home Screen", kGAIScreenName, nil];
[tracker send:params];

Check this link for more information

Upvotes: 1

Related Questions