Skip to content Skip to sidebar Skip to footer

Parse Push Notification Just Work In Emulator

I need help, because I am working with Parse Push Notification Android but my application just receives notifications in emulator but not receives in real devices. In my analytics

Solution 1:

use the following instead:

    // inform the Parse Cloud that it is ready for notifications
    PushService.setDefaultPushCallback(this, MainActivity.class);   
    ParseInstallation.getCurrentInstallation().saveInBackground(new SaveCallback() {
        @Override
        public void done(ParseException e) {
            if (e == null) {

            } else {
                e.printStackTrace();

            }
        }
    });

Solution 2:

i had the same problem and it was because i didn't check package name

<permission
    android:name="YOUR_PACKAGE.permission.C2D_MESSAGE"
    android:protectionLevel="signature" />

<uses-permission android:name="YOUR_PACKAGE.permission.C2D_MESSAGE" />

Post a Comment for "Parse Push Notification Just Work In Emulator"