android:isolatedProcess=";“真的”;使服务崩溃
我试图在一个单独的进程中启动服务,这样即使用户关闭应用程序,它也能运行 我搜索了一下,找到了一些解决方案。我采用了以下方式,但这会使服务崩溃android:isolatedProcess=";“真的”;使服务崩溃,android,performance,android-layout,android-fragments,android-service,Android,Performance,Android Layout,Android Fragments,Android Service,我试图在一个单独的进程中启动服务,这样即使用户关闭应用程序,它也能运行 我搜索了一下,找到了一些解决方案。我采用了以下方式,但这会使服务崩溃 Intent intent= new Intent(MainActivity.this, LocationUpdateService.class); startService(intent); 我在我的清单文件中添加了以下内容 <service android:name=".myservices.serv
Intent intent= new Intent(MainActivity.this, LocationUpdateService.class);
startService(intent);
我在我的清单
文件中添加了以下内容
<service android:name=".myservices.services.LocationUpdateService"
android:process=":locationservice"
android:isolatedProcess="true"
/>
请指导我需要采取哪些额外步骤才能在单独的流程中启动 撞车?logcat的输出是什么?logcat没有显示任何内容。应用程序也没有崩溃,但它给出了错误消息
,不幸的是,应用程序已停止
我不确定您是否要使用isolatedProcess,您的用例是:android:process@Kirmani88添加服务类代码以了解更多详细信息。