Tag Archives: MSBuild

MSB3026: Could not copy “xxx.dll” to “other/xxx.dll

With Visual Studio 2015 I have often the case that following MsBuild exception occurs

warning MSB3026: Could not copy “SomePath/SomeDll.dll” to “SomeOtherPath/SomeDll.dll”. Beginning retry 1 in 1000ms. The process cannot access the file ‘SomePath/SomeDll.dll’ because it is being used by another process.

To get rid of this exception just kill the Visual Studio 2015 Remove Debugger

You can also execute following Command Line command:

taskkill /f /fi "Imagename eq msvsmon.exe"
Leave a comment

Posted by on October 28, 2015 in Visual Studio


Tags: ,

Found conflicts between different versions of the same dependent assembly

warning MSB3277: Found conflicts between different versions of the same dependent assembly that could not be resolved. These reference conflicts are listed in the build log when log verbosity is set to detailed.

First of all Change build log verbosity to detailed. This is done by changing the value for Tools>Options>Project and Solutions>Build and Run>MSBuild project outbut verbosity to detailed.

After that you can rebuild the solution. During build time MSBuild writes a lot of information to the Output-View. After build completition you have to search the whole log file for the corresponding assembly conflict. You can do this by using CTRL+F to open the search-view, entering “conflict” and hitting the search button. Visual Studio highlights all corresponding matches. Search for a message that states a sentence like the following:

There was a conflict between “System.Windows.Interactivity, Version=, Culture=neutral, PublicKeyToken=31bf3856ad364e35” and “System.Windows.Interactivity, Version=, Culture=neutral, PublicKeyToken=31bf3856ad364e35”.
“System.Windows.Interactivity, Version=, Culture=neutral, PublicKeyToken=31bf3856ad364e35” was chosen because it was primary and “System.Windows.Interactivity, Version=, Culture=neutral, PublicKeyToken=31bf3856ad364e35” was not.

Just remove the reference to the wrong assembly from the current built project System.Windows.Interactivity, Version= and add the reference to the correct assembly System.Windows.Interactivity, Version= and the warning is gone when you build the Project the next time.

After that you are free to change the build verbosity back to the previous value.


Posted by on November 10, 2014 in C-Sharp


Tags: ,