Questions tagged [android-settings]

android-settings can refer to a class that contains constants values used to launch system preferences screens. For example, launch an intent to the network management screen.

The Settings provider contains global system-level device preferences. A list of these constants can be found here.

285 questions
156
votes
12 answers

Opening Android Settings programmatically

How can I open settings programmatically?
Behnam
  • 6,510
  • 6
  • 35
  • 65
52
votes
1 answer

How to open application permission window in app settings programmatically

I'm working on new permission model (Android 6.0 Marshmallow) and I wonder is there a way to open the application's permission window programmatically? not only application details I managed to open the second screen using something like…
38
votes
4 answers

How to Enable Android Download Manager

I'm using Android Download Manager to download list of files. Lately I came across a crash report saying Unknown java.lang.IllegalArgumentException: Unknown URL content://downloads/my_downloads Then later, I figured it out that the reason is…
37
votes
6 answers

Launching mobile network settings screen programmatically

I want to launch mobile network settings screen, so that user can enable/disable 3g or data connection. Can anybody tell me which intent I need to use for starting activity. I used Intent in = new…
sandeep
  • 937
  • 2
  • 12
  • 22
25
votes
2 answers

Go to settings screen

I want to open the Settings-> Sound & Display-> Phone Ringtones screen from my application. How can I do that?
lostInTransit
  • 70,519
  • 61
  • 198
  • 274
21
votes
3 answers

Enabling Location mode High Accuracy or Battery saving, programmatically, without user needing to visit Settings

Why i ask this:(also the reason for trying it in an app) It happens when we use Google Maps in Lollipop. Even if the Location is disabled, it is turned on, in high accuracy mode after user's input from the Maps app, without having to visit…
21
votes
2 answers

How to get programmatically the data usage limit set by user on Android OS configuration?

User can define at Data Usage screen a limite and/or a warning limit for mobile data usage. So how can I get this information by code? Screen of Data Usage configuration of native OS. I wanna the limit value and warning value. I've already tried…
20
votes
3 answers

Unique Android Device ID after MarshMallow warning "get device identifiers is not recommended"?

I saw one of my best question Is there a unique Android device ID? Edited: I need a solution for Android 10 too. I used some following code to get Unique Id. public static String getDeviceId(Activity context) { PermissionsChecker checker = new…
Pratik Butani
  • 60,504
  • 58
  • 273
  • 437
20
votes
3 answers

Access application notification settings programmatically

In an Android app, I have a button that I want to have the functionality of opening the App Notification settings (in Android settings). I can open the Android settings with this startActivityForResult(new…
Thought
  • 5,326
  • 7
  • 33
  • 69
17
votes
3 answers

Settings activity doesn't open on tablet

I have set up correctly the pref_general, values for it, and the code to run the intent: @Override public boolean onOptionsItemSelected(MenuItem item) { // Handle action bar item clicks here. The action bar will // automatically handle…
15
votes
3 answers

Android Studio is not selecting text properly

I guess accidentally pressing a key or a combination changed a setting in Android Studio after which android studio is acting weird and won't let me select code properly. Look at following image. I have checked Android Studio setting and couldn't…
user5508088
15
votes
1 answer

Android: Can I enable the GPS without redirecting the user to the settings screen like in "google maps" app

In GPS based applications, it is important that the user enable his GPS. If not then usually we would show a dialog stating that the user "should enable his GPS from the settings to be able to use this functionality". When the user press OK he will…
A.Alqadomi
  • 1,529
  • 3
  • 25
  • 33
14
votes
8 answers

Android navigate back to Application from Android Settings

I am having an inconsistent user experience due to the way android navigates back from Android Settings. In my application the user needs to give my app access to ACTION_USAGE_ACCESS_SETTINGS, which I access with the following: Intent intent = new…
Geordie Wicks
  • 1,065
  • 1
  • 11
  • 27
14
votes
3 answers

Change the system display size programmatically Android N

Background: Android N comes with a feature to change system Display Size from settings, in addition to the previously present feature of changing Font Size. Change Display Size: Image Source: pcmag.com Question: If an app has…
Shobhit Puri
  • 25,769
  • 11
  • 95
  • 124
13
votes
2 answers

How to know whether Notifications are enabled or not for an application in android?

I've a ListView which has the list of installed applications and for each application, I need to know whether the notifications are enabled or not. Currently I'm using below code to know if the notifications are enabled: appOpsClass =…
Ashraf
  • 143
  • 1
  • 8
1
2 3
18 19