Hi gkvoelkl,

Try this

Context context = pass_some_context;
ActivityManager activityManager = (ActivityManager)
context.getSystemService(Activity.ACTIVITY_SERVICE);
String packageName =
activityManager.getRunningTasks(1).get(0).topActivity.getPackageName();
String className =
activityManager.getRunningTasks(1).get(0).topActivity.getClassName();

Regards,
Sourav

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" 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-developers?hl=en

Reply via email to