David Overton's Blog and Discussion Site
This site is my way to share my views and general business and IT information with you about Microsoft, IT solutions for ISVs, technologists and businesses, large and small
This blog is purely the personal opinions of David Overton. If you can't find the information you were looking for e-mail me at admin@davidoverton.com. If you want to narrow down the content consider these links:
Windows SBS 2008 or SBS 2003 Office 2007 or Office 2003

To find out more about my SBS 2008 BOOK - Small Business Server 2008, Installation, Migration and Configuration click here

To read my wife’s blog on her dieting journey, go to her spaces blog
How to repair the .NET Framework 2.0 and 3.0 on Windows Vista
David Overton's Blog

Buy my book

SBS 2008 - Installation, Migration and Configuration

Small Business Server 2008 – Installation, Migration, and Configuration

Buy today in book or e-book form

Request a Review Copy

Syndication

My boss had some problems on his PC after installing some tools onto it and upon further diagnosis it appeared to be that the .Net Framework had been corrupted.  We did all the usual things of looking in "Add/Remove Programs" etc, adding service packs etc all to no avail.  I then came across this blog entry and a fix started to come to light

How to repair the .NET Framework 2.0 and 3.0 on Windows Vista

Since the Windows Vista public launch in January 2007, I have been receiving questions about how to repair the .NET Framework 2.0 and 3.0 to try to resolve various bugs.  As I previously described here, the 2.0 and 3.0 versions are installed as OS components on Windows Vista and do not appear in the Programs and Features (formerly known as Add/Remove Programs) control panel.

Many of the customers I have heard from have tried to use the .NET Framework cleanup tool, but it does not list the .NET Framework 2.0 as a valid removal option when it is run on Windows Vista.  This is by design - the cleanup tool does not offer the option to remove any version of the .NET Framework that is an OS component on the OS it is being run on.

Aaron Stebner's WebLog : How to repair the .NET Framework 2.0 and 3.0 on Windows Vista

 

The important things seem to be:

  1. Don't use the clean up tool
  2. Try the command "sfc /scannow" from an elevated command prompt
  3. Repair the (V2) framework with the command "%windir%\Microsoft.NET\Framework\v2.0.50727\ngen.exe update" again from an elevated command prompt

The 1st item stops corruption, then 2nd checks the OS's binary (core internal files) are correct and matching their signatures and the final one re-creates all the "native" files from the IL code.

 

ttfn

David


Posted Fri, Feb 1 2008 7:32 AM by David Overton

Comments

Korrumpiertes .NET-Framework in Windows Vista reparieren | Windows Vista Blog wrote Korrumpiertes .NET-Framework in Windows Vista reparieren | Windows Vista Blog
on Fri, Feb 1 2008 12:34 PM

Pingback from  Korrumpiertes .NET-Framework in Windows Vista reparieren | Windows Vista Blog

AL wrote re: How to repair the .NET Framework 2.0 and 3.0 on Windows Vista
on Fri, Apr 18 2008 5:34 PM

Thank you

Chris wrote re: How to repair the .NET Framework 2.0 and 3.0 on Windows Vista
on Tue, Oct 14 2008 7:22 PM

Thanks!

Alexandra wrote re: How to repair the .NET Framework 2.0 and 3.0 on Windows Vista
on Sun, Nov 9 2008 10:59 PM

I tried to repair this tool in all posible ways but even this does not work, is there something else i can do?

Shawn Harvey wrote re: How to repair the .NET Framework 2.0 and 3.0 on Windows Vista
on Wed, Jan 14 2009 8:07 AM

ER.... vista 7 beta failure:  After I tried to install the 2.0 sdk and fiddled around with starting a few (of the nearly 1,000) services.

to wit:

E:\Windows\Microsoft.NET\Framework\v2.0.50727>ngen update

Microsoft (R) CLR Native Image Generator - Version 2.0.50727.3521

Copyright (c) Microsoft Corporation.  All rights reserved.

Failed to load dependency Microsoft.MediaCenter of assembly ehExtHost32, Version

=6.0.6000.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35 because of the fol

lowing error : The system cannot find the file specified. (Exception from HRESUL

T: 0x80070002)

Failed to load dependency Microsoft.MediaCenter.UI of assembly ehExtHost32, Vers

ion=6.0.6000.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35 because of the

following error : The system cannot find the file specified. (Exception from HRE

SULT: 0x80070002)

Failed to load dependency ehiExtens of assembly ehExtHost32, Version=6.0.6000.0,

Culture=neutral, PublicKeyToken=31bf3856ad364e35 because of the following error

: The system cannot find the file specified. (Exception from HRESULT: 0x8007000

2)

Failed to load dependency stdole of assembly ehiVidCtl, Version=6.1.0.0, Culture

=neutral, PublicKeyToken=31bf3856ad364e35 because of the following error : The s

ystem cannot find the file specified. (Exception from HRESULT: 0x80070002)

Failed to load dependency stdole of assembly ehiVidCtl, Version=6.1.0.0, Culture

=neutral, PublicKeyToken=31bf3856ad364e35 because of the following error : The s

ystem cannot find the file specified. (Exception from HRESULT: 0x80070002)

All compilation targets are up to date.

From ngen.exe update (as you directed, kind sir).  I'm wondering if it can really not find it or if it's a victim of your Novell-on-Acid rights inheritance schema.  Ah, oh... did the sfc as well.  Does it just look at files or also the securities on them?

I'd kind of like to fix this because (kudos to MS and in a big way) this beta is more stable than the v6 I have on my other drives.  Not too crazy about a few features and it sticks once in a while but guess what, no bsods.  Now that's a major upgrade!  (no sarcasm implied -- I am impressed so far).

By the way, your level 2 and 3 tech support is superb.  Had to bring in a 3 for a 07 bsod with a gigabyte motherboard (they denied everything and hinted it was NVIDIA's fault- which is probably true).

David Overton wrote re: How to repair the .NET Framework 2.0 and 3.0 on Windows Vista
on Wed, Jan 14 2009 8:17 AM

I just checked the programs list on my Win 7 system - no dot net framework 2 - try installing it :-)

Winer Reales wrote re: How to repair the .NET Framework 2.0 and 3.0 on Windows Vista
on Wed, Mar 11 2009 1:27 PM

%windir%\Microsoft.NET\Framework\v2.0.50727\ngen.exe update

Help me but i must use Windows Installer CleanUp Utility u to clean rest from framework 1.1. If you need go to Microsoft and download.

support.microsoft.com/.../290301

anti.spy wrote re: How to repair the .NET Framework 2.0 and 3.0 on Windows Vista
on Sun, Apr 5 2009 1:49 AM

=please give me the link of net framework 2.0 for windows vista.

I downloaded some framework and its not compatible in windows vista. please give me the link...

David Overton wrote re: How to repair the .NET Framework 2.0 and 3.0 on Windows Vista
on Sun, Apr 5 2009 9:04 AM

Vista has .Net framework V2 built in, so there is no download needed.

Thanks

David

Emc78 wrote re: How to repair the .NET Framework 2.0 and 3.0 on Windows Vista
on Sun, Apr 19 2009 5:38 PM

Hi, I'm pretty sure I have >net 1.1 on my OS and I have tried the link in the command prompt. I get the ngen failed to initialize box, any idea's on how to repair my framework?

Thanks

em

mike wrote re: How to repair the .NET Framework 2.0 and 3.0 on Windows Vista
on Mon, Aug 24 2009 5:17 PM

worked!

great stuff..

thanks a lot

augied wrote re: How to repair the .NET Framework 2.0 and 3.0 on Windows Vista
on Mon, Sep 28 2009 1:06 AM

I guess I need a little help. I am not sure how to implement the

%windir%\Microsoft.NET\Framework\v2.0.50727\ngen.exe update

part of your solution

cLu3L3ss wrote re: How to repair the .NET Framework 2.0 and 3.0 on Windows Vista
on Fri, Oct 23 2009 11:06 AM

Okay I did what was said and the third one pulled this up

C:\Windows\system32>%\Mircrosoft.NET\Framework\v2.0.50727\ngen.exe update Microsoft <R> CLR Native Image Generator - Version 2.0.50727.3053 Copyright <c> Microsoft Corpooration. All rights reserved. Failed to load dependency Microsoft. Web.Administration of assembly Service Mode 1Reg, Version=3.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a because of the following error : The system cannot find the file specified. <Exception from HRESULT: 0x80070002> All compilation targets are up to date.

Brad wrote re: How to repair the .NET Framework 2.0 and 3.0 on Windows Vista
on Sat, Nov 7 2009 5:58 AM

Is there a comparable repair command for the x64 framework folder?

David Overton wrote re: How to repair the .NET Framework 2.0 and 3.0 on Windows Vista
on Sun, Nov 8 2009 10:19 AM

Brad,

I found the commands worked just fine on my system replacing Framework with Framework64.

Thanks

Daryl Petersen wrote re: How to repair the .NET Framework 2.0 and 3.0 on Windows Vista
on Wed, May 12 2010 9:47 PM

I had a corrupt System.Web.Dll (zero size) in the 2.0 framework folders on my Windows 7 machine that was causing all my issues (mainly with VS2010). Tried everything here to repair it but no luck. Ended up taking ownership and replacing the corrupt file with a copy from another machine.

Also tried all sorts of repair/reinstalls of the 2.0 framework but absolutely nothing worked. What a nightmare.

All good now though, AFAIK.

Lisa A wrote re: How to repair the .NET Framework 2.0 and 3.0 on Windows Vista
on Fri, Jun 18 2010 2:34 PM

I had a website that would crash with a .NET (2.0) error, and no amount of fixing I did repaired the problem - these instructions worked like a charm! THANK YOU!

Add a Comment

(optional)  
(optional)
(required)  
Remember Me?

(c)David Overton 2006-9