You can change the default download directory by setting this registry key:
HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\Download Directory
To write to the windows registry using Java you can either use the "reg" command. (type "reg /?" at a command prompt for details of the arguments):
Runtime.getRuntime().exec("reg [Your arguments]");
Or you can use a 3rd party registry library like
jRegistryKey[
^]