我在我的应用程序中使用了两个以上的服务,我应用了不同的解决方案,但它们都不起作用,应用程序在创建案例后在版本上被杀死。E/AndroidRuntime: FATAL EXCEPTION: main android.app.RemoteServiceException: Bad notification for startForeground: java.lang.RuntimeException: inv
如题,华为9.0手机,报 android.app.RemoteServiceException: Bad notification for startForeground: java.lang.RuntimeException: invalid channel for service notification
(Notification.CATEGORY_SERVICE) .build();
startForeground但是我在Android 8.1,9.0和10.0 Emulator上得到了下面的错误。android.app.RemoteServiceException: Bad notification for startForeground: java.lang.RuntimeE
只在android 11和10中得到了这个错误,其他的都很好,已经检查了这个问题,看起来我的代码没问题。startForeground fails with Bad notification for startForeground android.app.RemoteServiceException: Bad(1, notification); 我在Android 11中遇到错误 at android.app.ActivityThread$H.handleMessage
我有一个Service,我想在其中使用startForeground()函数: if (notif == null)在较新的Android版本中,一切都很好,没有错误,但在2.3.4中,我得到了错误:android.app.RemoteServiceException:Bad notification for startForeground:
java.la
我所面临的问题已经在8.1.0的stackoverflowWhen启动地面服务上报道过了,我收到了应用程序crash.Error日志的通知,在Android8.0和Android9中,below.ItssetSmallIcon(R.drawable.ic_stat_name) .build();
startForegrounddo heavy work on a background
只要我使用Android仿真程序来测试它,我的代码就能正常工作,但是一旦我构建了它并尝试在我的手机上使用它,我就会得到以下错误:
An uncaught Exception occurred onBad notification for startForeground: java.lang.RuntimeException: invalid channel for service notificationvibrate=null sound=null defaults=0x0 flags=0x40