In case you are using NotificationCompat.Builder
, you can use :
NotificationCompat.Builder mBuilder = new NotificationCompat.Builder(context)
mBuilder.setOngoing(true); //this will make ongoing notification
More Related Contents:
- How to display count of notifications in app launcher icon [duplicate]
- Custom notification layouts and text colors
- Android: remove notification from notification bar
- How to send parameters from a notification-click to an activity?
- Actionbar notification count icon (badge) like Google has
- Notification to restore a task rather than a specific activity?
- Notification click: activity already open
- How to create a notification with NotificationCompat.Builder?
- Firebase (FCM): open activity and pass data on notification click. android
- Detect a new Android notification
- How to make notification intent resume rather than making a new intent?
- catch on swipe to dismiss event
- android: running a background task using AlarmManager
- Android – Build a notification, TaskStackBuilder.addParentStack not working
- How to show daily offline notifications in Android 10?
- How to display multiple notifications in android
- How to close the status bar/notification panel after notification button click
- Disable sound from NotificationChannel
- How to execute a method by clicking a notification
- On Android 8.1 API 27 notification does not display
- How to set the app icon as the notification icon in the notification drawer
- Android foreground service notification not showing
- Dismiss Ongoing Android Notification Via Action Button Without Opening App
- open a specific activity from firebase notification
- Adding onClick Action To Button In Notification
- NotificationCompat.Builder doesn’t accept 2nd argument
- Starting app only if its not currently running
- Is possible set Expanded Notification as default in Big Text Notifications?
- Extract notification text from parcelable, contentView or contentIntent
- Check for access to notifications using NotificationListenerService