BUG: UPGRADE comments overload the task list in Visual Basic .NET or in Visual Basic 2005 after the Upgrade Wizard runs (313509)



The information in this article applies to:

  • Microsoft Visual Basic 2005
  • Microsoft Visual Basic .NET (2003)
  • Microsoft Visual Basic .NET (2002)

This article was previously published under Q313509

SYMPTOMS

Your system may stop responding under the following circumstances:
  • You upgrade a Microsoft Visual Basic 6.0 project to Visual Basic .NET or Visual Basic 2005 by using the Upgrade Wizard.
  • The upgrade generates a significant number of items in your TODO list.
  • You try to remove an item from the TODO list by deleting the code comments that are associated with that item.
NOTE: Although this problem is unlikely to occur under other circumstances, this problem is not limited to projects that have been upgraded. If you manually add a significant number of TODO comments, you may experience the same problem.

CAUSE

When you upgrade your project from Visual Basic 6.0 to Visual Basic .NET or Visual Basic 2005, the Upgrade Wizard may generate a significant number of TODO or UPGRADE comments. Whenever you address or remove one of these comments, the Task List is updated.

Note The Visual Basic .NET Upgrade Wizard is included in Visual Studio .NET Professional.

However, when the list of comments in the Task List increases, updates to the TODO list take more time. While Microsoft Visual Studio .NET or Microsoft Visual Studio 2005 is updating the Task List, the cursor changes to an hourglass, and the application may stop responding depending on the computer and the size of the Task List.

RESOLUTION

To work around this problem, use one of the following methods.

Method 1: Temporarily Change the BuildAction Property

  1. In Solution Explorer, right-click the file that you are editing, and then change the value of the BuildAction property to None. This removes all of the entries for this file from the Task List.
  2. Remove all of the UPGRADE comments while the file is migrated.
  3. After you have removed most of the comments, change the value of the BuildAction property back to Compile.
  4. Repeat steps 1 through 3 for each file in your project until the number of UPGRADE comments is reduced to a manageable number (that is, less than 1,000 or 2,000 comments).

    Note Make sure that you set the value of the BuildAction property back to Compile (or the original setting) for all of the files so that the project builds correctly.

Method 2: Temporarily Remove Tokens from Task List

  1. On the Tools menu, click Options.
  2. In the left pane of the Options dialog box, click Task List under the Environment folder. Notice that the Token list box includes the UPGRADE tokens (UPGRADE_ISSUE, UPGRADE_TODO, UPGRADE_WARNING).
  3. Click each of the UPGRADE tokens, and then click Delete to remove these tokens from the Task List.
  4. Address all of the UPGRADE comments for all of the files in your project, and then remove the comments from the files.
  5. After you remove most of the UPGRADE comments from the files in your project, follow these steps to add the UPGRADE tokens back to the Task List to locate the remaining UPGRADE comments:
    1. On the Tools menu, click Options.
    2. In the left pane of the Options dialog box, click Task List under the Environment folder.
    3. In the Name text box under Comment Tokens, type UPGRADE_ISSUE, and then click Add.
    4. Repeat step 5c for the UPGRADE_TODO and the UPGRADE_WARNING tokens.
    5. Click OK to close the Options dialog box.

STATUS

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

MORE INFORMATION

When the Upgrade Wizard moves through the code, the wizard may find items that you must manually migrate or check. The wizard inserts a comment before each portion of code that you must check. These comments include the UPGRADE_ISSUE, the UPGRADE_TODO, and/or the UPGRADE_WARNING tokens. These comments are logged in the Task List.

Steps to Reproduce Behavior

  1. In Visual Basic .NET or inVisual Basic 2005, open a large Visual Basic 6.0 application that contains 25 or more modules.
  2. The Upgrade Wizard starts by default. Complete the steps in the Upgrade Wizard.

    Note You can also open the Upgrade Wizard from a command prompt. This installs the Upgrade Wizard in the following folder:

    Visual Studio .NET Installation Folder\VB7\VBUpgrade

    Note You can also start the Upgrade Wizard from a command prompt. When you do this, the Upgrade Wizard is installed in the following folder:

    Visual Studio 2005 Installation Folder\VB\VBUpgrade

  3. Notice that your Visual Basic .NET or Visual Basic 2005 project includes thousands of entries in the Task List. Open any of the files in your Visual Basic .NET or Visual Basic 2005 project, and then try to remove one of the comments that contain the UPGRADE_ISSUE, the UPGRADE_TODO, or the UPGRADE_WARNING token. Notice how long the Task List takes to update.

REFERENCES

For more information, see the following topics in the Visual Studio .NET Help documentation:

Modification Type:MinorLast Reviewed:10/3/2006
Keywords:kbvs2005swept kbvs2005applies kbvs2002sp1sweep kbmigrate kbbug kbpending KB313509 kbAudDeveloper