Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
577 views
in Technique[技术] by (71.8m points)

assemblies - ASP.Net cannot create/shadow copy

I get this error repeatedly when developing ASP.Net applications:

  Cannot create/shadow copy 'XXXXX' when that file already exists

Where XXXXX is a random DLL. Typically the DLL is one of the DLLs from Microsoft's Enterprise Library, but it varies.

It's really random, and it's very frustrating. I will go hours without getting the error, and then get this error every 10-20 minutes.

I've seen several solutions. For instance, this question. I've tried using Clean Solution option, and I've also simply restarted my local IIS. However, it still occurs at the same random but persistent frequency.

I've also seen many people mention using this option in the config file:

<hostingEnvironment shadowCopyBinAssemblies="false" />

However, others have mentioned it being problematic, and it should definitely not be used in production.

So, should I just give up and try the shadowCopyBinAssemblies option? (And make sure not to copy this change to other environments.) Am I the only one who gets this issue that often?

Note: I am using Visual Studio 2008.

question from:https://stackoverflow.com/questions/1007200/asp-net-cannot-create-shadow-copy

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

Wait somewhere between 10-30 seconds and hit refresh. For some reason this always works for me.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

2.1m questions

2.1m answers

60 comments

56.9k users

...