Flurry in iPhone App
My question is :
1. when a download the Flurry SDK, must i give the real name of my app or can i give any name? 2. can some one give some code in how to test the Flurry, for开发者_如何学运维 example i would like to know the age of the user of my App. ( i have this information in my app when the user authenticate ).thanks for your answers.
I think there is no need to give the real name of the apps, that name for your identification. But you should give the correct API key for the corresponding application.
First you import the latest flurry package into your apps, and have to use this code,
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
[FlurryAPI startSession:@"YOUR APP KEY"];
[FlurryAPI logEvent:@"Application Started"];
[FlurryAPI setSessionReportsOnCloseEnabled:FALSE];
[FlurryAPI setSessionReportsOnPauseEnabled:FALSE];
}
Then wherever you want to track the event, then put the logEvent.
For Eg:
-(IBAction) MapAction : (id) sender
{
[FlurryAPI logEvent:@"Map Applications Clicked"];
}
This is the procedure for trace the applications and the particular events using Flurry. Then you have to login to flurry and find the number of users have used in your apps and which device they have used and find the locations of the user. But i donno, how to get the users personal details.
Thanks!
1- You may give any name on Flurry Dashboard on the website. In code, however, you must enter the correct API assigned to that app from the website. Something like this:
[Flurry startSession:@"SOMELONGPSEUDORANDOMSTRING"];
2- As for the user's age, I see that the SDK header has this declaration:
+ (void)setAge:(int)age;
To invoke this code, you would do something like this:
[Flurry setAge:myAgeVariable ];
精彩评论