Run command prompt as Administrator

  Runtime.getRuntime().exec("runas /profile /user:Administrator \"cmd.exe /c Powrprof.dll,SetSuspendState\"");

Also plz see comments

Running as admin without Admin rights

Leave a Comment