Microsoft.Practices.EnterpriseLibrary.Data.dll overwritten on build

Topics: Building and extending application blocks, Data Access Application Block
Sep 22, 2010 at 3:30 AM

I have a web site using EntLib 4.0.  The Microsoft.Practices.EnterpriseLibrary.Data.dll and Microsoft.Practices.EnterpriseLibrary.Common.dll files are overwritten in the bin directory every time I build.  They are automatically upgraded to the 5.0.414.0 version files.

I have no references to the 5.0.414.0 dll's anywhere on my system.  There are no references to classes or services that use the 5.0 dll's.  Still, every time I build the website, the dll's magically appear.

Any help would be greatly appreciated.

Sep 22, 2010 at 3:35 AM

But you have entlib 5.0 installed on your machine?  Are there any entlib 5.0 assemblies in GAC and does your entlib references show as Copy Local = false?


Sarah Urmeneta
Global Technology & Solutions
Avanade, Inc.

Sep 22, 2010 at 4:01 AM

I don't have the 5.0 installed or in the GAC.  I even deleted the files from the network directory where we house stored dll's.  The project is a web site type instead of a web project... so the references are marked auto update unless I delete the .refresh files.  I've deleted those and still get the overwrite.

It might be worth mentioning that the overwrite happens almost right away after I hit run or build.

I did update a WCF service recently to 5.0.  However, I did it manually by including the dll's and editing the web.config.  I deleted all references to that service once I started getting the errors caused by the automatic dll upgrade, though.

Sep 22, 2010 at 6:15 AM

And it still happens after deleting references to that service?  Any chance there are other assemblies you're referencing that uses EntLib 5.0? 


Sarah Urmeneta
Global Technology & Solutions
Avanade, Inc.

Sep 22, 2010 at 2:56 PM

Okay.  I got it fixed.  After your question about the other assemblies, I thought I'd go double check.  While checking it occurred to me that the assemblies would have to be pulling those dll's from somewhere.  Viola!  The 5.0 common and data dll's somehow ended up in our shared reference folder.  This is really strange since the enterprise library stuff is usually housed in a completely separate folder which I deleted earlier just to make sure it wasn't causing my issue.

I still have to wonder how the files ended up there or why they were getting pulled into my project without a reference...  But, either way, deleting them fixed my issue.

Thanks for the help.