broadcastreceiver - Get Notification even when app is not running -
hello can please me how notification on specific date when app not in running state, in advance
you have calculate exact date , transfer long type. set time in notification. looks like:
long time = system.currenttimemillis(); // example, should revise. notificationmanager manager = (notificationmanager) context.getsystemservice(context.notification_service); notification n = new notification(r.drawable.notification_icon, context.getstring(r.string.app_name), time); manager.notify(constants.notification_id, n);
Comments
Post a Comment