Important: Please read the Qt Code of Conduct -

Push Notification on Android Phone with Qt

  • Hi,

    I tried this example
    but I didn't receive any notification on the phone.
    I am running Qt5.12 and here is my main:

      QQmlApplicationEngine engine;
        NotificationClient *notificationClient = new NotificationClient(&engine);
        return app.exec();

    And on qml I just do this:

    notificationClient.notification = "Notification!"

    Any idea why? Do I need permission?
    Is there also a way to play sound on the notification like an alarm?

  • Lifetime Qt Champion


    What version of Android are you using ?
    Something is not clear, are you experiencing that with the example or with your own application ?

  • @SGaist I am using Android with OS 9 on a Samsung S9 with Qt5.12 and it is on my own application.

  • Lifetime Qt Champion

    What do you mean by own application ? I thought you were using the notification example ?

    Just one thing, your thread title mentions push notifications, this example doesn't implement them.

Log in to reply