Android Question starting app from notification icon

DT1111

Member
Licensed User
Longtime User
When I touched on the notification icon, I was expecting the action will bring the app, which was "minimized" in the background, back to the foreground. But that didn't happen. The app has a Starter service and Main. The Main loadlayout the GUI form.

I am wondering what is missing to enable the touching of notification icon to bring the app to the fore.

Thanks.
 

DonManfred

Expert
Licensed User
Longtime User
Without seeing your code it is nearly impossible to give concrete answers.
Please create a small project which shows the problem and upload it here
 
Upvote 0

DT1111

Member
Licensed User
Longtime User
Hi Manfred

The codes are

In Main ...
B4X:
Sub Activity_Create(FirstTime As Boolean)

    Activity.LoadLayout("Form")

End Sub


In Starter Service ...
B4X:
Sub Process_Globals

    Dim Notif As Notification

End Sub

Sub Service_Create

    Notif.Initialize
    Notif.Icon = "icon"
    Notif.Sound = False
    Notif.Vibrate = False

End Sub

Sub Service_Start (StartingIntent As Intent)
   
   
    Notif.SetInfo("MyApp","App Running...",Me)
    Notif.Notify(1)

End Sub
 
Upvote 0
Top