"Error generating Win32 resource" in Visual Studio, Windows 7 x64

Posted by Jerad Rose on Stack Overflow See other posts from Stack Overflow or by Jerad Rose
Published on 2010-05-18T17:35:35Z Indexed on 2010/05/18 17:40 UTC
Read the original article Hit count: 841

My co-developers and I recently upgraded machines to Windows 7 Ultimate 64 bit. Some of us are seeing a new error we used to never see when building solutions in Visual Studio (happens in both 2008 and 2010):

Error generating Win32 resource: The process cannot access the file because it is being used by another process.    

It always points to some temp file in our output folder, for example:

MyProject\obj\Debug\CSC5123.tmp

This happens about once every four or so builds. We then will try to run the same exact build again, and it will usually succeed. In some cases though, it will fail again on the same project, and in same cases, it will fail on a different project. There's really no rhyme or reason to it. But it's very frustrating, especially when it doesn't happen until the build has been running for 20 or so seconds.

This also doesn't happen to all of our coworkers. It happens to about one out of four developers. For the one, it happens about one of four builds, and for the other three, it never happens.

Oh, and did I mention we're all using machines built from the same image? :)

Thanks in advance for any direction you can provide.

© Stack Overflow or respective owner

Related posts about visual-studio

Related posts about visual-studio-2008