get the logged in user java code example
Example: get the logged in user java
String windowsUser = System.getProperty("user.name");
String windowsDomain = System.getenv("USERDOMAIN");
System.out.println ("User=" + windowsDomain + "\\" + windowsUser);