小编use*_*776的帖子

Android:另一个Activity中的stopService

如何在其他活动中停止我的服务?

我在summaryActivity中启动了该服务

SocketServiceIntent = new Intent(this, SocketService.class);
SocketServiceIntent.putExtra("MessageParcelable", mp);
startService(SocketServiceIntent);
Run Code Online (Sandbox Code Playgroud)

从我的summaryActivity开始我的statusActivity

Intent intent = new Intent(SummaryActivity.this,
                StatusActivity.class);
intent.putExtra("MessageParcelable", mp);
startActivity(intent);
Run Code Online (Sandbox Code Playgroud)

我的问题是我不知道如何将我的Statusactivity提供给SocketServiceIntent.

java service android android-intent

5
推荐指数
2
解决办法
1万
查看次数

标签 统计

android ×1

android-intent ×1

java ×1

service ×1