DetailPage-MSS-KB

Microsoft small business knowledge base

Article ID: 927511 - Last Review: October 8, 2011 - Revision: 5.0

Important This article contains information about how to modify the registry. Make sure that you back up the registry before you modify it. Make sure that you know how to restore the registry if a problem occurs. For more information about how to back up, restore, and modify the registry, click the following article number to view the article in the Microsoft Knowledge Base:
256986  (http://support.microsoft.com/kb/256986/ ) Description of the Microsoft Windows registry

Important notes

For users who have Microsoft Visual Studio 2005 Service Pack 1 installed

Visual Studio 2005 Service Pack 1 (SP1) is now available for download. This service pack includes all the Microsoft Visual Basic 2005 hotfixes that have been created to date. Visual Studio 2005 SP1 provides you the best overall performance and stability when you are developing in Visual Basic 2005.

For more information about Visual Studio 2005 SP1, visit the following Microsoft Developer Network (MSDN) Web site:
http://msdn2.microsoft.com/en-us/vstudio/bb265237.aspx (http://msdn2.microsoft.com/en-us/vstudio/bb265237.aspx)
The hotfix that is described in this article provides the same improvements for the Visual Basic 2005 command-line compiler (Vbc.exe) that are included with Visual Studio 2005 SP1. If you have Visual Studio 2005 SP1 installed, and if one of the following conditions is true, you must apply only the .NET Framework 2.0 hotfix that is included with this hotfix package:
  • You are developing Web sites by using Microsoft ASP.NET 2.0.
  • You are building solutions outside the Visual Studio 2005 IDE by using the Visual Basic 2005 command-line compiler.
You must apply this hotfix on both development computers and deployment computers to obtain the Visual Studio 2005 SP1 fixes for the Visual Basic 2005 command-line compiler. For more information, see the "File information" section.

For users who do not have Visual Studio 2005 SP1 installed

If you do not have Visual Studio 2005 SP1 installed, and you are experiencing the symptoms that are described in this article, you must apply both the hotfixes that are included in this hotfix package. For more information, see the "File information" section.

On This Page

SYMPTOMS

In Visual Studio 2005, you may experience the following problems.

Problem 1

When you import a generic type in a Visual Basic 2005 application, Visual Studio 2005 may exit unexpectedly (crash). Additionally, you may receive the following error message:
Microsoft Visual Basic Compiler has encountered a problem and needs to close. We are sorry for the inconvenience.

Problem 2

Under some special conditions, an interface member may be reimplemented incorrectly when you recompile a Visual Basic 2005 application.

RESOLUTION

Service pack information

To resolve this problem, obtain the latest service pack for Visual Studio 2005. For more information, click the following article number to view the article in the Microsoft Knowledge Base:
929697  (http://support.microsoft.com/kb/929697/ ) How to obtain the latest Visual Studio 2005 service pack

Hotfix information



A supported hotfix is available from Microsoft. However, this hotfix is intended to correct only the problem that is described in this article. Apply this hotfix only to systems that are experiencing this specific problem. This hotfix might receive additional testing. Therefore, if you are not severely affected by this problem, we recommend that you wait for the next software update that contains this hotfix.

To download this hotfix from the MSDN Code Gallery, visit the following Microsoft Web site:
http://code.msdn.microsoft.com/KB927511 (http://code.msdn.microsoft.com/KB927511)

Note The MSDN Code Gallery displays the languages for which the hotfix is available. If you do not see your language listed, it is because the Code Gallery resource page is not available for that language.

Note If additional issues occur or if any troubleshooting is required, you might have to create a separate service request. The usual support costs will apply to additional support questions and issues that do not qualify for this specific hotfix. For a complete list of Microsoft Customer Service and Support telephone numbers or to create a separate service request, visit the following Microsoft Web site:
http://support.microsoft.com/contactus/?ws=support (http://support.microsoft.com/contactus/?ws=support)

Prerequisites

You must have the Microsoft .NET Framework 2.0 and Visual Studio 2005 installed to apply this hotfix.

Restart requirement

You do not have to restart the computer after you apply this hotfix.

Hotfix replacement information

This hotfix replaces the hotfixes that are described in the following Microsoft Knowledge Base articles:
915038  (http://support.microsoft.com/kb/915038/ ) FIX: You may receive Visual Basic compiler error messages when you are developing a Visual Basic 2005 project in Visual Studio 2005
917452  (http://support.microsoft.com/kb/917452/ ) FIX: You may experience performance issues when you use solutions that contain large Visual Basic projects in Visual Studio 2005
919904  (http://support.microsoft.com/kb/919904/ ) FIX: You may receive an error message when you try to build a Web project that references a .NET Compact Framework 2.0 assembly in Visual Basic 2005
920145  (http://support.microsoft.com/kb/920145/ ) FIX: You may receive an error message when you consume an assembly that has an obfuscated generic type in Visual Studio 2005
920805  (http://support.microsoft.com/kb/920805/ ) FIX: You may experience slow performance when you work with a Visual Basic solution that contains many projects in Visual Studio 2005
924162  (http://support.microsoft.com/kb/924162/ ) FIX: The Visual Basic 2005 compiler unexpectedly exits when you expand an item in the Visual Studio 2005 Watch window after you install the hotfix from KB article 920805
926405  (http://support.microsoft.com/kb/926405/ ) FIX: The Visual Basic 2005 compiler unexpectedly exits when you work with a Visual Basic 2005-based project in Visual Studio 2005
926970  (http://support.microsoft.com/kb/926970/ ) FIX: You may experience a performance problem when you debug a Visual Basic 2005 application in Visual Studio 2005 if the source code is on a network share

Registry information

Warning Serious problems might occur if you modify the registry incorrectly by using Registry Editor or by using another method. These problems might require that you reinstall the operating system. Microsoft cannot guarantee that these problems can be solved. Modify the registry at your own risk.

If you have Visual Studio 2005 SP1 installed, you do not have to change the registry.

If you do not have Visual Studio 2005 SP1 installed, you must add and then enable the OptimizePDB registry entry to obtain the improved performance that this hotfix provides. To add the OptimizePDB registry entry, follow these steps:
  1. Click Start, click Run, type regedit, and then click OK.
  2. Locate and then right-click the following registry key:
    HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\8.0\VB Editor
    Note If you use Microsoft Visual Basic 2005 Express Edition, locate and then right-click the following registry key:
    HKEY_CURRENT_USER\Software\Microsoft\VBExpress\8.0\VB Editor
  3. Click New, and then click DWORD Value.
  4. Type OptimizePDB, and then press ENTER.
  5. Right-click OptimizePDB, and then click Modify.
  6. Type 1, and then click OK.
  7. Exit Registry Editor.
After you add the OptimizePDB registry entry, follow these steps:
  1. In Visual Studio 2005, start the Visual Basic application.
  2. On the Build menu, click Clean Solution.
Note The OptimizePDB registry entry improves the Visual Basic 2005 compiler. Therefore, the Visual Basic 2005 compiler can optimize the .pdb file. However, the new .pdb file format is not fully compatible with the old .pdb file format. Additionally, Visual Studio 2005 SP1 always uses the new .pdb file format. Therefore, a version of Visual Studio 2005 that does not have this hotfix applied or that does not have Visual Studio 2005 SP1 installed may be unable to recognize the new .pdb file format. To resolve this problem, use one of the following methods:
  • Apply this hotfix on all development computers.
  • Install Visual Studio 2005 SP1 on all development computers.
  • On the Build menu, click Clean Solution or click Rebuild Solution before you start to debug.

File information

This hotfix package includes the following hotfixes:
  • A Visual Studio 2005 hotfix
  • A .NET Framework 2.0 hotfix
If you have Visual Studio 2005 SP1 installed, and you are experiencing the symptoms that are described in this article, you must apply only the .NET Framework 2.0 hotfix to update the Visual Basic 2005 command-line compiler.

If you do not have Visual Studio 2005 SP1 installed, and you are experiencing the symptoms that are described in this article, you must apply both these hotfixes.

The English version of this hotfix package has the file attributes (or later file attributes) that are listed in the following table. The dates and times for these files are listed in Coordinated Universal Time (UTC). When you view the file information, it is converted to local time. To find the difference between UTC and local time, use the Time Zone tab in the Date and Time item in Control Panel.
Visual Studio 2005 hotfix, x86-based versions
Collapse this tableExpand this table
File nameFile versionFile sizeDateTimePlatform
Cpde.dll8.0.50727.246487,93620-Nov-200615:53x86
Msenv.dll8.0.50727.2469,107,45620-Nov-200616:08x86
Msvb7.dll8.0.50727.2463,144,70420-Nov-200616:10x86
Msvbprj.dll8.0.50727.2462,779,64820-Nov-200616:11x86
The .NET Framework 2.0 hotfix, x86-based versions
Collapse this tableExpand this table
File nameFile versionFile sizeDateTimePlatform
Vbc.exe8.0.50727.2361,164,03227-Oct-200622:05x86
Visual Studio 2005 hotfix, x64-based versions
Collapse this tableExpand this table
File nameFile versionFile sizeDateTimePlatform
Msvb7.dll8.0.50727.2462,162,68820-Nov-200611:19x64
The .NET Framework 2.0 hotfix, x64-based versions
Collapse this tableExpand this table
File nameFile versionFile sizeDateTimePlatform
Vbc.exe8.0.50727.2361,800,96027-Oct-200617:27x64
Visual Studio 2005 hotfix, Itanium-based versions
Collapse this tableExpand this table
File nameFile versionFile sizeDateTimePlatform
Msvb7.dll8.0.50727.2463,978,24020-Nov-200611:25IA-64
The .NET Framework 2.0 hotfix, Itanium-based versions
Collapse this tableExpand this table
File nameFile versionFile sizeDateTimePlatform
Vbc.exe8.0.50727.2362,994,94427-Oct-200618:23IA-64

STATUS

Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section. This problem was first corrected in Visual Studio 2005 Service Pack 1.

MORE INFORMATION

Steps to reproduce the problem

Problem 1

  1. Start Visual Studio 2005.
  2. On the File menu, click New Project.
  3. Under Project types, click Visual Basic.
  4. Under Templates, click Class Library.
  5. Type Test for the project name, and then click OK.
  6. In the Class1.vb file, replace the existing code with the following code.
    Imports Test.ContainerClass(Of Test.ConcreteClass)
    
    Public Class ErrorVB
    
        Private d As DateTime = DateTime.Now
    
        Public Sub Method1()
            Dim c1 As DateTime = d.Subtract(New TimeSpan(2, 0, 0, 0))
            Dim c2 As DateTime = d.AddDays(2)
    
            Dim x As InnerClass
    
        End Sub
    
        Public Sub Method2()
            Dim d1 As DateTime = d.Subtract(New TimeSpan(2, 0, 0, 0))
            Dim d2 As DateTime = d.AddDays(2)
    
            Dim x As InnerClass
    
        End Sub
    
    End Class
    
    Public Class ContainerClass(Of T)
    
        Public Class InnerClass
    
        End Class
    
    End Class
    
    Public Class ConcreteClass
    
    End Class

Problem 2

  1. Start Visual Studio 2005.
  2. On the File menu, click New Project.
  3. Under Project types, click Visual Basic.
  4. Under Templates, click Console Application.
  5. Type a project name, and then click OK.
  6. In the Module1.vb file, replace the existing code with the following code.
    Module Module1
    
        Sub Main()
            Dim I As I1
    
            I = New C2
            I.A()
    
            I = New C3
            I.A()
        End Sub
    
    End Module
    
    Class C1
        Implements I1
    
    
        Private Sub X() Implements I1.A
            Console.WriteLine("C1's implementation of I1.A")
        End Sub
    
        Private Sub Y() Implements I1.B
            Console.WriteLine("C1's implementation of I1.B")
        End Sub
    
    End Class
    
    Class C2
        Inherits C1
        Implements I1
    
        Overridable Sub A()
            Console.WriteLine("C2.A")
        End Sub
    End Class
    
    Class C3
        Inherits C1
        Implements I1
    
        Private Sub Z() Implements I1.B
            Console.WriteLine("C3's implementation of I1.B")
        End Sub
    
        Overridable Sub A()
            Console.WriteLine("C3.A")
        End Sub
    End Class
    
    Interface I1
        Sub A()
        Sub B()
    End Interface
  7. On the Build menu, click Build Solution.
You receive the following result:
C2.A
C3.A
However, you expect to receive the following result:
C1's implementation of I1.A
C1's implementation of I1.A
For more information about software update terminology, click the following article number to view the article in the Microsoft Knowledge Base:
824684  (http://support.microsoft.com/kb/824684/ ) Description of the standard terminology that is used to describe Microsoft software updates

APPLIES TO
  • Microsoft .NET Framework 2.0
  • Microsoft Visual Studio 2005 Team Edition for Software Architects
  • Microsoft Visual Studio 2005 Team Edition for Software Developers
  • Microsoft Visual Studio 2005 Team Edition for Software Testers
  • Microsoft Visual Studio 2005 Standard Edition
  • Microsoft Visual Studio 2005 Professional Edition
Keywords: 
kbqfe KB927511
Share
Additional support options
Ask The Microsoft Small Business Support Community
Contact Microsoft Small Business Support
Find Microsoft Small Business Support Certified Partner
Find a Microsoft Store For In-Person Small Business Support