---
title: "The amazing CLR runtime re-appearing trick"
url: "https://osherove.com/blog/2004/3/18/the-amazing-clr-runtime-re-appearing-trick.md"
canonical: "https://osherove.com/blog/2004/3/18/the-amazing-clr-runtime-re-appearing-trick.html"
published: "2004-03-18T21:16:00"
updated: "2004-03-18T21:16:00"
tags: [".Net Original"]
author: "Roy Osherove"
description: "[ Update : Joseph cooney alerted me to the fact that this is probably cause by Windows File Protection , and he was totally right. Coolness! Here's a very good article about this subject.] Here's a CLR party trick for…"
usage: "Licensed under CC BY 4.0 — reuse, quote and adapt with attribution (Roy Osherove, link to the original page)."
license: "https://creativecommons.org/licenses/by/4.0/"
---

# The amazing CLR runtime re-appearing trick

By Roy Osherove March 18, 2004 In [.Net Original](https://osherove.com/blog/category/net-original)

**Historical article** · Originally published March 18, 2004; technical details may be outdated.

_\[**Update**: [Joseph cooney](http://www.dotnetjunkies.com/weblog/JosephCooney/) alerted me to the fact that this is probably cause by **Windows File Protection**, and he was totally right. Coolness!_ [_Here's a very good article_](http://www.techspot.com/tweaks/wfp/index.shtml) _about this subject.\]_

Here's a CLR party trick for you:

- if you have .Net 1.1 installed on your machine
- Go to the location of your mscorlib.dll file (usually c:\\WINDOWS\\Microsoft.NET\\Framework\\v1.1.4322\\mscorlib.dll)
- **Rename or move** mscorlib.dll to some place where it will not be found
- Try to run a program that uses .net 1.1
- **Your app will load and work just fine**
- Look at the original location of the file you just renamed/moved
- Automagically - mscorlib.dll will be there, as if you never touched it, restored by some unknown force in the matrix.

Note: this only works for the .Net 1.1 runtime. Try the same stunt with mscorlib.dll version 1.0 and your app won't load.

I do wonder what is the process behind this. Anyone have any clue?

## More in .Net Original

[All posts in .Net Original](https://osherove.com/blog/category/net-original)

- Mar 19, 2004

    ### [Test Driven Development enters mainstream following MSDN Magazine article](https://osherove.com/blog/2004/3/19/test-driven-development-enters-mainstream-following-msdn-mag.html)

- Mar 19, 2004

    ### [Running The Regulator on .Net 1.0](https://osherove.com/blog/2004/3/19/running-the-regulator-on-net-10.html)

- Mar 18, 2004

    ### [DevDays grab-bag should be improved](https://osherove.com/blog/2004/3/18/devdays-grab-bag-should-be-improved.html)

- Mar 18, 2004

    ### [RegexLib's web service pays off big time.](https://osherove.com/blog/2004/3/18/regexlibs-web-service-pays-off-big-time.html)


---

## About the author

**Roy Osherove**: Senior Solutions Architect at AWS working on AI for production and AI-driven development; author of The Art of Unit Testing and Elastic Leadership, with about 20 years of consulting and training on unit testing, TDD, team leadership and continuous delivery.

### Sites

- [RobotPaper](https://robotpaper.ai/): This blog: AI patterns and anti-patterns, AI and coding agents, and engineering leadership.
- [osherove.com](https://osherove.com): Roy's personal site. Author of The Art of Unit Testing and Elastic Leadership; consulting and training on unit testing, TDD, team leadership and continuous delivery, plus about 20 years of blog posts.
- [The Art of Unit Testing](https://www.artofunittesting.com): The Art of Unit Testing, 3rd Edition (Manning): readable, maintainable, trustworthy unit tests, plus TDD workshops in C#, JavaScript, Java and Kotlin.
- [5whys.com](https://www.5whys.com): Roy's writing on software team leadership: self-organizing teams, surviving chaos, learning mode and the Elastic Leadership model.
- [Pipeline Driven](https://pipelinedriven.org): Continuous delivery and DevOps practices: build patterns, pipeline-friendly testing, DevOps metrics and enterprise DevOps.
- [Elastic Leadership](https://www.elasticleadership.com): Elastic Leadership, Roy's framework for software team leaders (survival, learning and self-organizing modes).

### Social

- X: https://x.com/royosherove
- LinkedIn: https://www.linkedin.com/in/osherove/

### Contact

- Contact form: https://forms.gle/jQSx5KoXvrVA1JCK7

### License

Licensed under CC BY 4.0 — reuse, quote and adapt with attribution (Roy Osherove, link to the original page). License: https://creativecommons.org/licenses/by/4.0/
