I was having this exact problem, and the issue was that Windows could not locate the 'TEMP' directory. Details:
OS: Win 7, up to date
Problems
- I was getting the above error when installing some programs
- When installing other programs, I was getting errors saying the program could not access a file
- Some programs that were installed were having problems (Google Sync in particular) and could not be uninstalled.
- Some icons (particularly internet bookmarks) were not showing up (generic 'blank page' shown instead)
Issue
I have C: located on a 128GB SSD, and had moved all unnecessary files to one of my platter drives to save space. This included the Windows 'TEMP' and 'TMP' directories. The platter drive with TEMP on it then failed. I could boot into Windows, but any task
using those directories would not work. When programs are (un)installing, they write/read to the TEMP dirs during the process.
Fix
Change the location of TEMP and TMP.
- Go into the start menu and type 'environment' into the search box.
- Select 'Edit environment variables for your account'
- Select the TEMP listing in the top box and point it to a location that exists.
- Repeat for TMP
- If they are already pointing at a real location, you could scan the drive for errors. Otherwise, this is likely not the problem you are having.
I think the 'small SSD, large platter drives' setup is becoming more common, so this error could become more prevalent.