In my android application, I wanna restart my android device on button click. But its working in rooted Phone,but not in un rooted phone.
try {
Runtime.getRuntime().exec(new String[]{"su","-c","reboot now"}));
} catch (IOException e) {
e.printStackTrace();
} catch (InterruptedException e) {
e.printStackTrace();
}
Is it possible to reboot both rooted & unrooted android devices?