package com;
import java.io.IOException;
public class LockMachine {
public static void main(String[] args) {
String WINDOWS_LOCK_COMMAND="rundll32.exe user32.dll, LockWorkStation";
Runtime rt = Runtime.getRuntime();
try {
rt.exec(WINDOWS_LOCK_COMMAND);
} catch (IOException e1) {
e1.printStackTrace();
}
}
}
Monday, August 1, 2011
How to lock Windows using Java Program
Subscribe to:
Post Comments (Atom)

2 comments:
that was nice way to know how to interrupt using a Java program..
it was nice new way to know how to interrupt using a Java program
Post a Comment