Pass result from DeviceAdminReceiver back to calling activity
问题 My activity (MyActivity.class) executes the method to set the screen lock as follow: startActivityForResult(Security.setLockscreen(getBaseContext()), 1001); Then my receiver class logs the change to the screen lock as follow: public class MyDeviceAdminReceiver extends DeviceAdminReceiver { @Override public void onPasswordChanged(Context context, Intent intent) { super.onPasswordChanged(context, intent); // pass result back to calling activity intent = new Intent(context, MyActivity.class);