mirror of
https://github.com/KeymonSoft/SoporteKeymonsoft.git
synced 2026-04-17 20:56:09 +00:00
Commit inicial
This commit is contained in:
37
notis.bas
Normal file
37
notis.bas
Normal file
@@ -0,0 +1,37 @@
|
||||
B4A=true
|
||||
Group=Default Group
|
||||
ModulesStructureVersion=1
|
||||
Type=Service
|
||||
Version=11.5
|
||||
@EndOfDesignText@
|
||||
#Region Service Attributes
|
||||
#StartAtBoot: False
|
||||
|
||||
#End Region
|
||||
|
||||
Sub Process_Globals
|
||||
'These global variables will be declared once when the application starts.
|
||||
'These variables can be accessed from all modules.
|
||||
|
||||
End Sub
|
||||
|
||||
Sub Service_Create
|
||||
|
||||
End Sub
|
||||
|
||||
Sub Service_Start (StartingIntent As Intent)
|
||||
Service.StopAutomaticForeground 'Call this when the background task completes (if there is one)
|
||||
Service.StartForeground(12345, CreateNotification("..."))
|
||||
End Sub
|
||||
|
||||
Sub Service_Destroy
|
||||
|
||||
End Sub
|
||||
|
||||
Sub CreateNotification (Body As String) As Notification
|
||||
Dim notification As Notification
|
||||
notification.Initialize2(notification.IMPORTANCE_LOW)
|
||||
notification.Icon = "icon"
|
||||
notification.SetInfo("Soporte", Body, Main)
|
||||
Return notification
|
||||
End Sub
|
||||
Reference in New Issue
Block a user