Skip to content Skip to sidebar Skip to footer

GCM Notification Doesn't Show Up In The Notification Bar. Android

I have tested my application on my phone and eclipse emulator(targeted at google api level 16), but the coming notification will only show up in the notification bar in the real ph

Solution 1:

Can you check that you can get a regID when you work on emulator?

GCMRegistrar.checkDevice(this);
GCMRegistrar.checkManifest(this);

final String regId = GCMRegistrar.getRegistrationId(this);
if (regId.equals("")) {
  GCMRegistrar.register(this, SENDER_ID);
} else {
  Log.v(TAG, "Already registered");
}

Post a Comment for "GCM Notification Doesn't Show Up In The Notification Bar. Android"