foreground-service Questions

4

Solved

I am currently writing my first Android application and I keep running into references to background and foreground services. Since I intend on using a service in my application I was hoping to get...

4

I have implemented Foreground Service using WorkManager, it works fine upto API Level 33. Since it is mandatory in API Level 34 to specify foregroundServiceType, I specified it in Worker and in the...
Hurtle asked 22/8, 2023 at 2:33

4

Solved

I have an Android application that worked fine until Android 13. After upgrading to Android 14 (Setting targetSdkVersion as 34) my application is Crashing on Android 14. Here's my crash log. java.l...
Coe asked 21/8, 2023 at 8:56

1

Solved

My exercise app uses a foreground service to keep an accurate timer going when a user turns off the screen whilst exercising. There's both a countdown and indefinite count-up timer option. This wor...
Infatuated asked 9/12, 2023 at 10:30

10

Solved

I am trying to stop a service which is running as foreground service. The current issue is that when I call stopService() the notification still stays. So in my solution I have added a receiver w...
Exposure asked 31/12, 2013 at 12:4

1

For fetching the location from foreeground service, we have recently migrated our WorkManager to use ForegroundService. We have followed the below document to achieve this: https://developer.androi...
Popularize asked 22/3, 2021 at 9:41

1

I have an app that uses a sticky foreground service to do some Bluetooth operations, it was working well untill android 14 release. I got this trace from Firebase although I am not able to reproduc...
Dilative asked 18/12, 2023 at 15:57

2

I'm writing an android app that tracks the user's location and shows the distance, time and price of the trip in a notification, all this tracked in a ForegroundService. The service tracks the loca...
Bimetallic asked 20/8, 2018 at 18:47

4

Solved

I'm currently trying to make some kind of music player app. For playback I created a separate service. Because I want to keep it playing all the time, I'm calling Service.startForeground(). While c...

0

Android 14 has made it compulsory to declare a proper foreground service type for foreground services. Details here. Three new foreground types have been introduced, of which specialUse is one. It ...
Bioluminescence asked 25/8, 2023 at 20:39

3

Sorry for the sort of click-bait title; I couldn't think of a more concise way to say it. In Android 13, if the user doesn't grant the "dangerous" POST_NOTIFICATION permission, then Foreg...
Mccracken asked 17/6, 2022 at 19:52

2

Solved

I noticed some very strange behavior when testing foreground notifications on Android 9. Situation: I have some foreground services where I don't know how long they'll need to run for, be it 1 sec...
Hulbig asked 30/12, 2019 at 5:47

2

Solved

I want to stop a foreground service which extends MediaLibrarySession only after clicking a specific button on the activity, so i tried : val serviceIntent = Intent(this@PartyHostActivity, PlayerSe...
Lightship asked 11/5, 2023 at 22:4

2

I am using React Native together with Expo to build an app for tracking workouts. I want to implement a foreground service for ongoing workouts but also to keep Expo in my project. I tried to use t...

2

Solved

I am making a foreground service and as we know that such services need a notification to keep running. However since Android 13, the user can dismiss it just by swiping, thus the app is killed. I ...

8

Solved

First of all, I looked at these; Context.startForegroundService() did not then call Service.startForeground() Context.startForegroundService() did not then call Service.startForeground Android 9 ...
Numbers asked 28/4, 2019 at 21:15

5

Solved

Context: I have been using Google's LocationUpdatesForegroundService example project to learn a bit more about services. I have downloaded the project via Github desktop and ran it on my phone, e...
Hail asked 16/2, 2019 at 22:38

2

Solved

I'm trying to create a foreground service in MAUI (using .NET 6) for an Android app, but currently, there are no tutorials (that I could find) on achieving this. What would be the best starting poi...
That asked 23/9, 2022 at 15:8

1

I have built an android app that performs some downloads followed by some time consuming processing. My goal here is to do the downloading and the processing in the background. I have read about ba...

3

Solved

I use startForeground to make my service "persist" in background and not be killed by the OS. I remove the service in the main activity onDestroy method by calling stopForeground and stopService. T...
Afterthought asked 16/11, 2018 at 8:43

1

Solved

I have an app that runs a stopwatch service, and I run the service in the foreground. I have a notification showing the timer, that updates each second. The notification stops updating 30 seconds a...

1

I'm trying to use new Notification API setForegroundServiceBehavior. However, when trying to create a build I'm getting an unresolved reference I believe in Android S in general. (I'm working on a ...
Barnett asked 28/1, 2022 at 13:17

0

I simply cannot understand why my phone kills my foreground service. Relevant code In AndroidManifest: <service android:name=".recorder.RecorderService" android:exported="false...
Umbrageous asked 17/2, 2022 at 22:34

1

Note: This question assumes you know binding a service to a context. Everyone on the production is aware of this issue, or even some users that have an Android Oreo or Pie device. The exception l...

2

I'm using flutter dart for developed the for foreground app to keep the app running in background on Android. It's working fine until phone is on lock screen the app is show the notification is sti...
Breed asked 8/6, 2020 at 5:19

© 2022 - 2024 — McMap. All rights reserved.