> I want to adjust display settings in my activity.
>
> Intent intent=new Intent(Settings.ACTION_DISPLAY_SETTINGS);
> startActivity(intent);
>
> got exception:
>
> 09-24 21:24:35.901: ERROR/AndroidRuntime(5892):
> android.content.ActivityNotFoundException:
> No Activity found to handle Intent
> { action=android.settings.DISPLAY_SETTINGS }
Per the docs:
"In some cases, a matching Activity may not exist, so ensure you safeguard
against this."
You can use methods on PackageManager to try to determine if there is an
activity that will respond to your Intent, in case you want to
conditionally disable launching that Intent or something.
--
Mark Murphy (a Commons Guy)
http://commonsware.com
Android App Developer Books: http://commonsware.com/books.html
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Beginners" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-beginners?hl=en
-~----------~----~----~----~------~----~------~--~---