iI had the exact same problem. iI tried installing the IDE in another laptop and uploaded the program from that laptop. Problem solved. then iThen I came back to my laptop, uninstalled the IDE and re-install it.. it worksstarted working.
howeverHowever, iI wasn't satisfied because i cantI couldn't find the source of the problem... so iI tried running everything again the same exact way.. i. I found the problem but not sure if that can be the actual cause of it..
inIn my project, iI needed to carry out serial communication between arduino and MATLAB (GUI).. inIn order to see/verify the output(type) of MATLAB (GUI) serial data, iI used HYPERTERMINAL and also VIRTUAL SERIAL PORT EMULATOR. iI noticed that every time when when hyperterminal is running or VSPE is running while my serial monitor is on it screws up the uploading feature of the program. imI'm not sure if itsit's because of the VSPE or HYPERTERMINAL, but reinstalling the IDE worked for me. :-)