B4A Tutorial Background location tracking - Erel    Jul 16, 2023   (50 reactions)   tags: Longrunningaoo, background clock alive, B4A Background location, gps, B4A editor: SetServiceAttribute(Tracker, android:foregroundServiceType, "location") Updates...https://www.b4x.com/basic4android/images/SS-2018-11-29_15.48.38.png Simple example of a foreground service that keeps the process running in the background. The current location is shown in the persistent notification. The app starts at boot and theoretically should run all the time. It also schedules itself to run with StartServiceAt. This can help in cases where the OS kills the process... B4A Question A question about receivers and foregroundServiceStartNotAllowed Exception - tufanv    May 23, 2023 Sub
What can cause the foregroundServiceStartNotAllowed Exception here? callsub to a main? Or... As Intent)
Service.StopAutomaticForeground 'remove if not using B4A v8+.
End Sub... B4A Question [Solved] Foreground service for all versions ? - lemonisdead    Sep 28, 2018   (1 reaction) a service has to run always and to be sure it runs on all Android versions, I have to :
- start the service as it is with the new AutomaticForegroundMode
- in Service_Start :
1) StopAutomaticForeground
2) Prepare a notification using NB6
3) put the service in foreground mode again using : Service.StartForeground
4) acquire a PartialLock
If the app is swipped, as we don't have Sticky... B4A Question Crash reports - ForegroundServiceStartNotAllowedException and ClassCastException - Robert Valentino    Feb 15, 2023 devices
This one seems to be saying something about startForegroundService but in B4XPages server I only have Service.StopAutomaticForeground
Type java.lang.RuntimeException
Exception java.lang... B4A Question SDK31 Android12 can't executing services on background ... Error: startForegroundService() not allowed due to mAllowStartForeground false - scsjc    Nov 24, 2022 com.xxxxxxxxx.starter$starter_BR: android.app.ForegroundServiceStartNotAllowedException: startForegroundService() not allowed due to mAllowStartForeground false: service com.xxxxxxxxxx/.starter... Italian background service vs. foreground service - sirjo66    May 12, 2022 service e un foreground service ???
ho un programma che utilizza il android.app.Service.START_STICKY e che devo quindi modificare con le nuove procedure.
Il servizio utilizza StartServiceAt per... B4A Tutorial Automatic Foreground Mode - Erel    Jun 12, 2018   (18 reactions)   tags: Mode, service foreground, Automatic Foreground Mode, Automatic, Foreground, Services any visible activity or any service in foreground state (Service.StartForeground). Common cases where we expect services to start even if the app is not in the foreground: - Push notifications... in the foreground is with a new API that ensures that the service will start and immediately switch to foreground mode. This is now handled automatically in the B4A framework. When needed services... foreground mode when the service completed its task. This can be done in two ways: 1. Call Service... B4A Tutorial Receivers and Services in 2023+ - Erel    Jan 18, 2023   (31 reactions) run for a short time. There is no similar feature to foreground services where a service can continue....ForegroundServiceStartNotAllowedException: startForegroundService() not allowed due to mAllowStartForeground...In the early days of Android services were simple to use and powerful. They allowed doing all kinds... versions of Android. With a few exceptions (that aren't 100% reliable), the only use case for services... is received. 'Do not assume that anything else, including the starter service, has run before... B4A Question MyLocation example causes error: No resource identifier found for attribute 'foregroundServiceType' in package 'android' - toby    Feb 8, 2021 attribute 'foregroundServiceType' in package 'android'
... B4A Question Notifications, foreground services... - LucaMs    Jan 13, 2020 what happens with MyLocation.
I got this by modifying this line:
Service.StartForeground(nid, CreateNotification("..."))
this way:
Service.StartForeground(0, Null)
This works but then... Page: 1   2   3   4   5   |