PC SOFT

WINDEVWEBDEV AND WINDEV MOBILE
ONLINE HELP

Home | Sign in | English UK
  • Overview
  • The notifications in the system bar
  • Other types of notifications
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile
Others
Stored procedures
Android: The different types of notifications
Overview
Android proposes several types of notifications to inform the user:
WINDEV Mobile allows you to use these different modes of notifications.
The notifications in the system bar
The notifications found at the top of the Android home screen are notifications by icons.
They ca be expanded to show their details.
To create and handle these notifications, WINDEV Mobile proposes:
You have the ability to add and delete icons (and their details) to/from the notification bar, to perform sound notifications, vibrations and to switch the LED on.
Versions 23 and later
Change of behavior for the notifications: From Android 8 (Oreo, API level 26), the notifications of Android applications must be added into a "channel". A "channel" corresponds to a group of notifications with its own setting: importance, vibration, sound, ... The user can enable or disable all channel notifications and modify these different parameters.
From WINDEV Mobile 23 Update 3, the notifications displayed by an Android application generated by WINDEV Mobile are automatically added into a channel corresponding to the priority of notification. The notification parameters (vibration, sound and LED display) can be modified according to the priority of notification and modifications performed by the end user on these parameters. Advanced management options are available in version 24.
New in version 23
Change of behavior for the notifications: From Android 8 (Oreo, API level 26), the notifications of Android applications must be added into a "channel". A "channel" corresponds to a group of notifications with its own setting: importance, vibration, sound, ... The user can enable or disable all channel notifications and modify these different parameters.
From WINDEV Mobile 23 Update 3, the notifications displayed by an Android application generated by WINDEV Mobile are automatically added into a channel corresponding to the priority of notification. The notification parameters (vibration, sound and LED display) can be modified according to the priority of notification and modifications performed by the end user on these parameters. Advanced management options are available in version 24.
Change of behavior for the notifications: From Android 8 (Oreo, API level 26), the notifications of Android applications must be added into a "channel". A "channel" corresponds to a group of notifications with its own setting: importance, vibration, sound, ... The user can enable or disable all channel notifications and modify these different parameters.
From WINDEV Mobile 23 Update 3, the notifications displayed by an Android application generated by WINDEV Mobile are automatically added into a channel corresponding to the priority of notification. The notification parameters (vibration, sound and LED display) can be modified according to the priority of notification and modifications performed by the end user on these parameters. Advanced management options are available in version 24.
Versions 24 and later
New notification behavior: using notification categories:
From Android 8.0 (Oreo, API level 26), all the notifications created by an Android application must be associated with a notification category also known as "channel".
Categories allow you to group notifications by "theme" (or another grouping criterion the developer decides to apply). Each notification category consists of an identifier, a name, a description, a level of priority and a set of visual and audio settings (sound, vibration, led color). When a notification is associated with a category, it automatically "inherits" its characteristics.
The end user can locally modify the notification settings of an application : enable/disable the notification display for the category, modify the notification priority, associate a particular sound, etc. These modifications are made from the application's notification settings screen :
New in version 24
New notification behavior: using notification categories:
From Android 8.0 (Oreo, API level 26), all the notifications created by an Android application must be associated with a notification category also known as "channel".
Categories allow you to group notifications by "theme" (or another grouping criterion the developer decides to apply). Each notification category consists of an identifier, a name, a description, a level of priority and a set of visual and audio settings (sound, vibration, led color). When a notification is associated with a category, it automatically "inherits" its characteristics.
The end user can locally modify the notification settings of an application : enable/disable the notification display for the category, modify the notification priority, associate a particular sound, etc. These modifications are made from the application's notification settings screen :
New notification behavior: using notification categories:
From Android 8.0 (Oreo, API level 26), all the notifications created by an Android application must be associated with a notification category also known as "channel".
Categories allow you to group notifications by "theme" (or another grouping criterion the developer decides to apply). Each notification category consists of an identifier, a name, a description, a level of priority and a set of visual and audio settings (sound, vibration, led color). When a notification is associated with a category, it automatically "inherits" its characteristics.
The end user can locally modify the notification settings of an application : enable/disable the notification display for the category, modify the notification priority, associate a particular sound, etc. These modifications are made from the application's notification settings screen :
Other types of notifications
WINDEV Mobile proposes other types of notifications.
1. Notification by vibration
The notification by vibration consists in making the device vibrate to warn the user.
Several WLanguage functions are used to manage this type of notification:
VibrationStopStops the vibrations of the device (even if they have been triggered by another application).
VibrationTriggerTriggers the vibrations of the device.
2. Notification by switching the LED on
The notification by lighting the LED consists in switching the device LED on (or in making it blink). On some devices, you also have the ability to change the color of the LED.
Several WLanguage functions are used to manage this type of notification:
LEDSwitchOffSwitches the LED (Light-Emitting Diode) of the device off.
LEDSwitchOnSwitches the LED (Light-Emitting Diode) of the device on.
3. Notification by Toast message
A Toast is a furtive message that appears in the middle or at the bottom of the screen to inform the user. The user does not have to validate the message: this one is displayed during a specified period of time.
Toast messages
The Toast messages are managed by the following WLanguage function:
ToastDisplayDisplays a "Toast" message.
Related Examples:
Android System Android (WINDEV Mobile): Android System
[ + ] This application is a tutorial example presenting some of the new features of WINDEV Mobile for Android.
The following system functions are used:
- NFC
- Multimedia control
- Brightness
- Volume
- WIFI
- Bluetooth
- Toast
- Progress Bar control
- 9-image mode
- Compass
- Accelerometer
- Camera control
- LED
- Vibrations
- Notifications
- Drawing functions
- Internet
Android Push Cross-platform examples (WINDEV Mobile): Android Push
[ + ] This example explains how to receive Push notifications on Android.

It calls the PushNotifActive function and returns the identifier to the WINDEV "WD Push Server" example that stores it.

Then, this identifier is read by the WINDEV "WD Send Push" example that sends the Push notifications to this Android example.
Minimum version required
  • Version 16
Comments
Click [Add] to post a comment