Android - Menü für Mobilfunknetz-Einstellungen (Jelly Bean)

Der folgende Code funktioniert nicht für Jelly Bean (Android 4.1):

final ComponentName cn = new ComponentName("com.android.phone","com.android.phone.Settings");
final Intent intent=new Intent(Settings.ACTION_DATA_ROAMING_SETTINGS);
intent.addCategory(Intent.CATEGORY_LAUNCHER);
intent.setComponent(cn);
intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
startActivity(intent);

Anstatt mit dem Einstellen zu beginnen, gibt es keine Ahnung, wie man es löst?

Hier ist Lösung:

final ComponentName cn = new ComponentName("com.android.phone","com.android.phone.MobileNetworkSettings");
final Intent intent = new Intent(Settings.ACTION_DATA_ROAMING_SETTINGS);
intent.addCategory(Intent.ACTION_MAIN);
intent.setComponent(cn);
intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
startActivity(intent);

Danke Jungs : )

Antworten auf die Frage(2)

Ihre Antwort auf die Frage