Notice: This website is an unofficial Microsoft Knowledge Base (hereinafter KB) archive and is intended to provide a reliable access to deleted content from Microsoft KB. All KB articles are owned by Microsoft Corporation. Read full disclaimer for more details.

Error message when you install SQL Server 2005 or SQL Server 2008: "The file C:\Windows\Microsoft.NET\Framework\[version_number]\mscorlib.tlb could not be loaded"


Symptoms

When you install Microsoft SQL Server 2005 or Microsoft SQL Server 2008, you receive the following error message:
The file C:\Windows\Microsoft.NET\Framework\version_number\mscorlib.tlb could not be loaded. An attempt to repair this condition failed because the file could not be found. Please reinstall this program.
Note version_number is a placeholder for the version number of the Microsoft .NET Framework, such as v1.0.3705, v1.1.4870, or v2.0.50727.

After you install SQL Server 2005 or SQL Server 2008, you may receive an error message that resembles this error message every time that you start Microsoft SQL Server Management Studio.

↑ Back to the top


Cause

This issue occurs because the path of the Mscorlib.tlb file is incorrectly interpreted during the Setup process.

↑ Back to the top


Workaround

Important This section, method, or task contains steps that tell you how to modify the registry. However, serious problems might occur if you modify the registry incorrectly. Therefore, make sure that you follow these steps carefully. For added protection, back up the registry before you modify it. Then, you can restore the registry if a problem occurs. For more information about how to back up and restore the registry, click the following article number to view the article in the Microsoft Knowledge Base:
322756 How to back up and restore the registry in Windows
To have us work around this problem for you, go to the "Fix it for me" section. If you prefer to fix this problem yourself, go to the "Let me fix it myself" section.

Fix it for me



To fix this problem automatically, click the Fix it button or link. Then click Run in the File Download dialog box, and follow the steps in the Fix it wizard.




Notes
  • If the problem that is described in this article still exists after you install the service pack or the hotfix, you must run this package again to work around this problem.
  • This wizard may be in English only. However, the automatic fix also works for other language versions of Windows.
  • If you are not on the computer that has the problem, save the Fix it solution to a flash drive or a CD and then run it on the computer that has the problem.

Then, go to the "Did this fix the problem?" section.



Let me fix it myself

For SQL Server 2005

To work around this problem, you must manually specify the correct path of the Mscorlib.tlb file in the registry. To do this, follow these steps:
  1. Click Start, click Run, type regedit, and then click OK.
  2. Locate the following registry subkey:
    HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SQL Server\90\Tools\Shell\TlbAutoRepair\mscorlib.tlb
    Notes
    • If you install SQL Server 2005 on 64-bit operating systems, locate the following registry subkey:
      HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\Microsoft SQL Server\90\Tools\Shell\TlbAutoRepair\mscorlib.tlb
    • If you install SQL Server 2005 Express Edition with Advanced Services, locate the following registry subkey:
      HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SQL Server\90\Tools\ShellSEM\TlbAutoRepair\mscorlib.tlb
  3. In the right pane, double-click the registry entry TlbPath. The Edit String dialog box appears.
  4. In the Value data box,replace %CLRVERSION% with the following value:
    v2.0.50727
    Note The value v2.0.50727 indicates the version of the .NET Framework that the original release version of SQL Server 2005 uses.
  5. Click OK, and then exit Registry Editor.
Important If you install a SQL Server 2005 service pack or hotfix, the service pack or hotfix will change the value that you replace in step 4 back to %CLRVERSION%. If the problem that is described in this article still exists after you install the service pack or the hotfix, you must following these steps again to work around this problem.

For SQL Server 2008

To work around this problem, you must manually specify the correct path of the Mscorlib.tlb file in the registry. To do this, follow these steps:
  1. Click Start, click Run, type regedit, and then click OK.
  2. Locate the following registry subkey:
    HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SQL Server\100\Tools\Shell\TlbAutoRepair\mscorlib.tlb Notes
    If you install the 32-bit version of SQL Server 2008 on 64-bit operating systems, locate the following registry subkey:
    HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\Microsoft SQL Server\100\Tools\Shell\TlbAutoRepair\mscorlib.tlb

    If you install SQL Server 2008 Express Edition with Advanced Services, locate the following registry subkey:
    HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SQL Server\100\Tools\ShellSEM\TlbAutoRepair\mscorlib.tlb
  3. In the right pane, double-click TlbPath.
  4. In the Value data box, replace %CLRVERSION% with the following value:
    v2.0.50727
    NoteThe value v2.0.50727 indicates the version of the .NET Framework that the original release version of SQL Server 2008 uses.
  5. Click OK, and then exit Registry Editor.
Important If you install a SQL Server 2008 service pack or hotfix, the service pack or hotfix will change the value that you replace in step 4 back to %CLRVERSION%. If the problem that is described in this article still exists after you install the service pack or the hotfix, you must following these steps again to work around this problem.


Did this fix the problem?

  • Check whether the problem is fixed. If the problem is fixed, you are finished with this section. If the problem is not fixed, you can contact support.
  • We would appreciate your feedback. To provide feedback or to report any issues with this solution, please leave a comment on the "Fix it for me" blog or send us an email message.

↑ Back to the top


Status

Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section.


↑ Back to the top


Keywords: kbsql2005setup, kbsql2005error, kbexpertiseadvanced, kbtshoot, kbprb, kbfixme, kbmsifixme, kb

↑ Back to the top

Article Info
Article ID : 918685
Revision : 3
Created on : 4/17/2018
Published on : 4/18/2018
Exists online : False
Views : 79