如何禁用管理appliaction的应用信息的清除数据按钮 [英] How to disable the Clear Data button in Application info of Manage appliaction

查看:287
本文介绍了如何禁用管理appliaction的应用信息的清除数据按钮的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的工作在Android 2.2,Android中的应用程序选项卡文件中体现提供了允许清除数据选项,设置true或false。但是,将其设置为False后,我的应用程序不能禁用管理应用的应用信息的清除数据的按钮。我面临这个问题,当应用程序包含数据库中的数据/数据​​/装箱率名/数据库/。

I am working on android 2.2, In a Application tab of android manifest provide the option of "Allow clear data" to set true or false. But after setting it to False, my application can't disable the button of Clear data in application info of Manage application. I am facing this problem when application contains database in Data/Data/packge-name/databases/.

我已经度过我的2天这个问题,但结果是零,。 我要保护我的应用程序数据库与用户。请帮我。

I already spend my 2 days for this issue, but result is zero,. I have to protect my application database from user. Please help me.

推荐答案

有没有办法为prevent从清除您的应用程序数据的用户。你提到的清单选项仅用于系统的应用程序,你,作为一个开发者,都没有办法安装系统的应用程序。

There is no way to prevent the user from clearing your app data. The manifest option you mention is intended for system apps only and you, as a developer, have no way to install system apps.

请参阅这个讨论了解详细信息 - 特别是的黛安Hackborn(Android框架工程师)的响应。

Please see this discussion for details - particularly this response from Diane Hackborn (Android framework engineer)

这篇关于如何禁用管理appliaction的应用信息的清除数据按钮的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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