1) process list------tasklist
2)To open a pdf file------start "" /max "c:\nameofpdf.pdf"
3)to shutdown---------shutdown /s
4)to restart---------shutdown /r
5)for playing vlc-----
String path= "C:\\Users\\name\\Desktop\\as.mp4";
String command1 = "cmd.exe /c cd C:/Program Files/VideoLAN/VLC &cmd.exe /k \"vlc \""+path+"\" --video-filter=scene --start-time=0 --stop-time=89 vlc://quit\"";
Process p = RunTime.getRunTime.exec(command1);
6)to open all types of files and folders remotely
public void open_files(String abspath) {
try {
Runtime r = Runtime.getRuntime();
String path = "cmd.exe /c start \"\" /max \"" + abspath + "\"";
System.out.println("path = " + path);
Process p = r.exec(path);
} catch (Exception e) {
}
}
2)To open a pdf file------start "" /max "c:\nameofpdf.pdf"
3)to shutdown---------shutdown /s
4)to restart---------shutdown /r
5)for playing vlc-----
String path= "C:\\Users\\name\\Desktop\\as.mp4";
String command1 = "cmd.exe /c cd C:/Program Files/VideoLAN/VLC &cmd.exe /k \"vlc \""+path+"\" --video-filter=scene --start-time=0 --stop-time=89 vlc://quit\"";
Process p = RunTime.getRunTime.exec(command1);
6)to open all types of files and folders remotely
public void open_files(String abspath) {
try {
Runtime r = Runtime.getRuntime();
String path = "cmd.exe /c start \"\" /max \"" + abspath + "\"";
System.out.println("path = " + path);
Process p = r.exec(path);
} catch (Exception e) {
}
}
No comments:
Post a Comment