Wednesday, January 30, 2008

Visual Studio throws error while building: The process cannot access the file as it is being used by another process.

The error "The process cannot access the file as it is being used by another process." is thrown by Visual Studio (here 2005) if an assembly, that is used by the building process, is blocked by another process.

A useful program to find the blocking process is Process Explorer (v11.04). Furthermore, you should check other sessions on the development system and, also, other machines that could have the same solution opened remotely.