Android Question How to create a Full-Screen Notification in B4A for Android 9?

madrigal115

Member
Licensed User
Hello,
I am trying to show a full-screen notification in B4A when a new order arrives. I want it to open an Activity called Request.




Here is my code snippet:
How do I correctly create a PendingIntent in B4A using JavaObject to open an Activity?:
Dim n As NB6
Dim cs As CSBuilder
Dim bmpSign As Bitmap = LoadBitmapResize(File.DirAssets, "sign.png", 24dip, 24dip, False)
Dim title As Object = cs.Initialize.Color(Colors.Red).Append("Caution:").PopAll
Dim Content As Object = cs.Initialize.Append("This app may drain your battery!").PopAll
Dim largeIcon As Bitmap = LoadBitmapResize(File.DirAssets, "Small Cartoon.png", 256dip, 256dip, True)
n.Initialize("default", Application.LabelName, "DEFAULT").AutoCancel(True).SmallIcon(bmpSign)
n.LargeIcon(largeIcon)
' Here I want to open Request Activity
' n.FullScreenIntent = ???
Return n.Build(title, Content, "tag", Me)
 
Top