error CS0016: Could not write to output file - build problems - vs.net

From: Quinn Wilson (Quinn.Wilson_at_nygard.com)
Date: 05/20/04


Date: 20 May 2004 09:57:31 -0700

MS please provide a solution to this.

Windows 2000 / Visual Studio 7.0.9466 / .Net Framework v1.1.4322

I have a solution ( based on the MS Commerce Server International
Retail Site Reference ) which contains 12 projects. (7 VB and 4 C#)

If I open the IDE, click [Build / Rebuild Solution], my compile is
successfull. If I click [Build / Rebuild Solution] again, the compile
dies on one of the C# projects.

Performing main compilation...
error CS0016: Could not write to output file
'd:\onlinestore\Components\obj\DebugAll\Microsoft.CommerceServer.Retail2002.Components.dll'
-- 'The process cannot
access the file because it is being used by another process. '

and no subsequent compile attempts will succeed. My only solution thus
far has been to exit the IDE, delete the "obj" directory of the
offending project, ( Depending on the build order it is not always the
same but it is always a C# project / never VB. ) rebuild the solution
from the commandline "devenv /build debugall
d:\onlinestore\Retail2002.sln"

I have followed the direction in QB313512
I do not have projects that are compiled to the same output folder. I
have only project references, and none of the references to these
projects are marked with "Copy Local" as false. (I should note that
this wasn't always a problem. I suspect that I reached the 64kb limit
mentioned in the KB article and began experiencing these issues. )

I have resorted to managing the build process manually using the
Configuration Manager to enable and disable the projects I'm working
on, but if I have to make a change to any of the C# projects I am
forced to reopen the IDE.

If anyone has any suggestions. I am open to anything. If it means
reworking my solution, that's fine. I would prefer to continue my
builds within the IDE but this is increasingly more painfull.

Frustrated



Relevant Pages

  • Re: Compile errors in VB6 running in VirtualPC
    ... using the "Shared Folders" functionality of VirtualPC. ... Trying to open VB6 projects would fail with "Path not found ... The VB6 IDE could now open and compile ...
    (microsoft.public.vb.com)
  • Re: Compile errors in VB6 running in VirtualPC
    ... using the "Shared Folders" functionality of VirtualPC. ... Trying to open VB6 projects would fail with "Path not found ... The VB6 IDE could now open and compile ...
    (microsoft.public.vb.com)
  • Re: Problem with VB crashing
    ... They compile without any problem - and ... I still also have the weird problem where I can only run reports ... with Crystal if I'm running in the IDE, ... inconvenient, but I can live with it since it only affects me. ...
    (microsoft.public.vb.general.discussion)
  • Re: Odd problem with Visual Studio
    ... > If I launch one copy of the IDE, then I can usually compile the project at ... > sharing a couple of the assemblies. ... I did locate one circular reference that ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: Solution Build question / issue....
    ... Both compiles are in Release mode, IDE and command line. ... What we did is in the Support DLL there are three calls to the HTTPContext ... compile from the IDE the variables do get set. ...
    (microsoft.public.dotnet.framework.aspnet)