A few weeks ago, I got the HTC Evo 4G and I downloaded the proper files to start developing applications for the android market. As I was trying to install the android SDK, I encountered an error where I had to force http in order to download the sdk and the updates. I looked at the "SDK Readme.txt" file and I ran in the command-line ´toolsandroid.bat update sdk´ but It couldn´t find the JAVA SDK.
After looking through the batch file android.bat, I found out that it calls another batch file "find_java.bat" to find the JAVA SDK. The problem is that if you have the 32-bit Java SDK, it is not installed in the "Program Files" folder but in the "Program Files (x86)". So I went to the system properties of my computer and I created a new enviromental variable, called it "ProgramFles" and the value is the path to the "Program Files (x86)" folder. Then I opened the find_java.bat file and changed line 44 from ´for /D %%a in ( "%ProgramFiles%Java*" ) do call :TestJavaDir "%%a"´ to ´for /D %%a in ( "%ProgramFles%Java*" ) do call :TestJavaDir "%%a"´.
Finally I went back to the command-line, executed again ´toolsandroid.bat update sdk´ and everything got installed.