private static int openURLWindows(String url) throws IOException {
  url=url.replace("&","^&");
  String[] command=new String[]{"cmd.exe","/c","start",url};
  ProcessBuilder pb=new ProcessBuilder(command);
  pb.start();
  return 0;
}

private static int openURLWindows ( String url ) throws IOException { url = url . replace ( "&" , "^&" ) ; String [ ] command = new String [ ] { "cmd.exe" , "/c" , "start" , url } ; ProcessBuilder pb = new ProcessBuilder ( command ) ; pb . start ( ) ; return 0 ; }
opens the default web browser on windows , passing it the specified url .
