custom-notificaiton

Remoteview displays system notification when App is not in the foreground or not running instead of Custom Notification

戏子无情 提交于 2019-12-12 18:54:11
问题 First of all, let me tell you what I have done so far. I have gone through lots of searching including Remoteview is not applied in background firebase_messaging not customizing notification when an app is not in the foreground Also, I have referred GitHub and lots of articles but none of these worked for me so that is the reason I am posting this question, so please do not mark this as duplicate. Its Working fine when App is Running, but it displays system notification when the app is in

Programatically Set Custom Notification Ringtone (Choose from AUDIO files in Mobile) for App

℡╲_俬逩灬. 提交于 2019-12-11 04:09:52
问题 I want to list all the available AUDIO (.mp3) files in Mobile device. User can select any Audio file from list and can set as a Notification Tone for this App. I worked out many sources and none of them satisfiable. Thank you. 回答1: First get all the available mp3 files and retreive their names using the code below do whatever u want with the retreived data for eg u can set up to a list view or showing them in a dialog etc. String extPath = getSecondaryStorage(); if (extPath != null) { mySongs

android.app.RemoteServiceException: Bad notification posted from package. Couldn't expand RemoteViews for: StatusBarNotification

扶醉桌前 提交于 2019-12-01 21:13:44
问题 I have implemented custom notification with RemoteViews widget. I tested it on Android 5.0.2 and Android 6.0. It was working fine. But after sometime, it started crashing everytime it received notification from GCM. Crash Dump - Process: package.name, PID: 27743 android.app.RemoteServiceException: Bad notification posted from package package.name: Couldn't expand RemoteViews for: StatusBarNotification(pkg=package.name user=UserHandle{0} id=1524095391 tag=null key=0|package.name|1524095391

android.app.RemoteServiceException: Bad notification posted from package. Couldn't expand RemoteViews for: StatusBarNotification

我是研究僧i 提交于 2019-12-01 18:48:26
I have implemented custom notification with RemoteViews widget. I tested it on Android 5.0.2 and Android 6.0. It was working fine. But after sometime, it started crashing everytime it received notification from GCM. Crash Dump - Process: package.name, PID: 27743 android.app.RemoteServiceException: Bad notification posted from package package.name: Couldn't expand RemoteViews for: StatusBarNotification(pkg=package.name user=UserHandle{0} id=1524095391 tag=null key=0|package.name|1524095391|null|10247: Notification(pri=0 contentView=package.name/0x7f040033 vibrate=null sound=null defaults=0x0