我怎样才能让在后台我的Andr​​oid应用程序运行? [英] How can I make my android app run on the background?

查看:210
本文介绍了我怎样才能让在后台我的Andr​​oid应用程序运行?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我建立一个收集有关电池数据的应用程序。为了收集这些数据,我需要我的应用程序,以便能够收集这些数据在后台运行。
我该怎么办呢?

I build an application that collects data about the battery. In order to collect this data I need my application to run on the background in order to be able to collect this data. How can I do it?

推荐答案

您需要更改活动纳入的服务

You need to change your activities into Service

这篇关于我怎样才能让在后台我的Andr​​oid应用程序运行?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆