views:

206

answers:

3

Hello,

I have a PreferenceScreen that is defined in XML that serves all the preferences for my application. This PreferenceScreen also has a child PreferenceScreen nested within it. My implementing class is called PreferencesActivity. I know I can open the main Preferences window via startActivity(new Intent(this, PreferencesActivity.class)); but how do I go about opening the child PreferenceScreen via an Intent?

A: 

I would also like to know this.

then increase a score of original question (when you'll can), and not post this as an answer
zed_0xff
A: 

hi - i researched a while on this topic for my project Theft Aware (http://www.theftaware.com) (a little bit advertisement... :-) and i found the solution:

PreferenceScreen screen = getPreferenceScreen(); // gets the main preference screen screen.onItemClick(null, null, , 0); // click on the item

where is the position of the item you want to open on the screen

best regards Reinhard

Reinhard
A: 

oh - in my example something was removed by the server, here again:

hi - i researched a while on this topic for my project Theft Aware (http://www.theftaware.com) (a little bit advertisement... :-) and i found the solution:

PreferenceScreen screen = getPreferenceScreen(); // gets the main preference screen screen.onItemClick(null, null, INDEX , 0); // click on the item

where INDEX is the position of the item you want to open on the screen

best regards Reinhard

Reinhard
Thank you very much!!! I am wondering if this can be adapted to make the positioning of the items agnostic.
Mike