File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Security and the fly likes java.lang.SecurityException: Permission Denial in android Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Engineering » Security
Bookmark "java.lang.SecurityException: Permission Denial in android" Watch "java.lang.SecurityException: Permission Denial in android" New topic
Author

java.lang.SecurityException: Permission Denial in android

rashmi swamy
Greenhorn

Joined: Oct 05, 2010
Posts: 14
Hi,
I am trying to disable the application by using following code in android

PackageManager pm = this.getPackageManager();
pm.setComponentEnabledSetting(new ComponentName("com.sasken.remotesample",".Player"),
PackageManager.COMPONENT_ENABLED_STATE_DEFAULT, PackageManager.DONT_KILL_APP);

and with permission in Androimanifest.xml is
<uses-permission android:name="android.permission.CHANGE_COMPONENT_ENABLED_STATE"/>

But it is giving me the exception

java.lang.SecurityException: Permission Denial: attempt to change component state

Please give me the solution
dogan kose
Greenhorn

Joined: Aug 01, 2013
Posts: 1
hi man
I have the same problem.
if you solved this problem,you can help me.
[UD: removed email address]
I am waiting for your answer.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: java.lang.SecurityException: Permission Denial in android