when would broadcast "com.android.vending.INSTALL_REFERRER" get send?
android, google-play
Solution
"Remember that the rest of your app won’t be running when the receiver is called so usually you record the referrer string somewhere such as SharedPreferences and then when the main app is run gather it up and use analytics libraries. (You certainly don’t want to block processing in the receiver waiting for network connections and similar!)
Reference
Problem
Here is my question My goal is to track app installs from google play. I have a BroadcastReceiver written in my app. So when the app gets downloaded from the goole play, there will be a broadcast "com.android.vending.INSTALL_REFERRER" according to the google page: https://developers.google.com/analytics/devguides/collection/android/v2/campaigns But my question is the if this happens while my app is getting installed, then how can I initiate my broadcastreceiver which comes with the app, to receive this intent.? In other words, my logic is that my app has to finish installing in order for me do perform any receiving. Or does it mean, the intent that starts my app for the first time is the "com.android.vending.INSTALL_REFERRER" intent, so that intent gets passed in to my onCreate() function. I am bit confused here, and dont see like finding some good documentations for this. Anybody point me the right direction? Thanks.