Jaa


Upgrading Visual Basic 6.0 Applications to Visual Basic .NET and Visual Basic 2005

 

Retired Content

This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This page may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.

patterns & practices Developer Center

patterns & practices Developer Center

October 2005

Summary

This page provides an overview of the Upgrading Visual Basic 6.0 to Visual Basic .NET and Visual Basic 2005 guide. This guide was developed jointly by the Microsoft patterns & practices team and ArtinSoft, a company with vast experience in Visual Basic upgrades and the developer of the Visual Basic Upgrade Wizard and the Visual Basic Upgrade Wizard Companion. This guide provides valuable information for organizations who are considering upgrading their Visual Basic 6.0-based applications and components to Visual Basic .NET. It provides proven practices to reach functional equivalence with a minimal amount of effort and cost and guidance for common advancements after the application is running on the .NET framework.

In addition to the guidance itself, a new tool, the Visual Basic 6.0 Upgrade Assessment Tool, is provided to give your organization assistance in identifying common upgrade issues and estimating the cost and effort required to upgrade your Visual Basic 6.0 code.

Downloads
Community
  • http://practices.gotdotnet.com/projects/vb62vbnet [Content link no longer available, original URL:http://practices.gotdotnet.com/projects/vb62vbnet]
License

Contents

Overview
Community
Future Plans
Feedback and Support
Authors and Contributors
Related Titles and Resources

Overview

Many companies have invested time and money in the development of applications built on the Visual Basic 6.0 language and related technologies. Despite the release of Visual Basic .NET, there has been hesitation in adapting these applications for the new version of the language. Although information about performing such upgrades can be found throughout the Web, comprehensive guidance that covers all aspects of upgrading has been lacking.

The purpose of this guide is to provide this comprehensive guidance. The guide discusses everything from the initial assessment and planning stages, to practical development solutions for the issues that arise during an upgrade, to the testing of upgraded applications. The best practices for achieving functional equivalence with the minimal amount of cost and effort are also discussed. Based on ArtinSoft's extensive experience with Visual Basic 6.0 upgrade projects, the practices, processes, and procedures provided in the guidance have been proven effective. There are also suggestions for advancing upgraded applications with new technologies available in Visual Basic .NET after functional equivalence is reached.

In addition to the guidance itself, a newly developed tool, the Visual Basic 6.0 Upgrade Assessment Tool, is provided to generate reports that an upgrade team can use to estimate the cost and effort of performing an upgrade on a particular application, component, or project. The tool analyzes Visual Basic 6.0 source code to identify issues that require manual attention to properly address. For each issue, the tool provides an estimate for the amount of time and the developer skill required to address it. These estimates and suggestions are based on ArtinSoft's extensive experience in upgrading Visual Basic 6.0 components and applications to Visual Basic .NET. After the tool analyzes your code, it produces reports in the form of Microsoft Excel worksheets that detail the analysis of the code. The information provided includes source code metrics (such as the number of forms, modules, and lines of code per file), the number and categories of upgrade issues that need to be addressed, and a recommended upgrade order. There are also estimates for the amount of effort and cost to perform the upgrade (broken down by task and totaled) and suggestions for the developer resources needed to perform the upgrade. These estimates are configurable so that you can adjust the estimates to reflect the resources and level of experience available in your company. Detailed information about using the assessment tool and interpreting and modifying the reports is provided in the guide.

Benefits

The guide is based on extensive experience in performing upgrade projects on a wide range of Visual Basic 6.0-based applications. The knowledge gained during these upgrades has helped to produce the best practices that can be applied by anyone performing such an upgrade, and these practices have been captured in the form of this guide. The benefit for the reader is that the provided practices, processes, and procedures have been thoroughly tested over many different projects over many domains and have shown to be effective.

An added benefit is the assessment tool that was produced in conjunction with this guide. The assessment tool can analyze existing Visual Basic 6.0 code to assess the amount of manual effort that must be applied to upgrade an application to Visual Basic .NET. It identifies upgrade issues in code and assesses the severity of each issue based on effort required to address it. The benefit is that much of the work in determining the feasibility and cost and effort estimates for an upgrade project can be automated.

Audience Requirements

This guidance is intended for technical decision makers, solution architects, and software developers. To perform upgrades using this guidance, you should have an understanding of the following technologies:

  • Microsoft Visual Basic 6.0
  • Microsoft Visual Basic .NET
  • Microsoft .NET Framework 1.1 and .NET Framework 2.0

Concepts and Features of the Guide

The guidance covers several aspects of the upgrade process, including:

  • General upgrade strategies.
  • Initial assessment.
  • Planning and preparation.
  • Automatic upgrade procedures.
  • Upgrade issues.
  • Manual upgrade processes.
  • Application advancement.
  • Testing upgraded applications and components.

The guide discusses each of these aspects and includes practical examples that reinforce and demonstrate each discussion.

The guide begins with a general overview of upgrading. This includes discussions of why you might want to consider an upgrade project and alternatives to upgrading, and a discussion of the information you need to gather to make the best informed decisions.

The guide next follows with information about the upgrade process itself. Several tools for assisting with upgrades are discussed, including the Visual Basic 6.0 Upgrade Assessment Tool and the Visual Basic Upgrade Wizard. It details the processes for preparing applications before applying the tools to achieve maximum benefits. Furthermore, the features of the Visual Basic 6.0 language that are supported and the limitations of the upgrade wizard are provided so that you can understand the "why" behind each process or suggestion.

The guide moves on to the continuation of the upgrade process after the automated upgrade tool finishes its work. Because there are limitations to what the tool can automatically upgrade, manual upgrade effort will have to be performed to complete the upgrade. The guide shows the types of issues that require manual attention, providing both details of each issue's source and the solution. Each solution includes code examples to provide practical demonstration. The issues discussed cover the complete range of possible Visual Basic 6.0 application types, from classic Windows Forms-based applications to Web-based applications, and more general language features such as data types, file input/output, database access, and distributed computing technologies.

For applications in which complete upgrade is impractical because of time or budget constraints, the guidance provides information for achieving interoperability between Visual Basic 6.0 and Visual Basic .NET. This allows you to upgrade portions of a project or application while leaving others in Visual Basic 6.0. Through these interoperability techniques, those parts of your application that are too costly to upgrade can be left in Visual Basic 6.0 indefinitely, leaving you free to upgrade them if and when the resources to upgrade them become available.

After you upgrade an application to Visual Basic .NET, you can begin to take advantage of features and technologies previously unavailable in earlier versions of the language. The guide provides suggestions for the types of advancements you can make to your applications and offers advice about how to achieve them. For those advancements that are too extensive to cover in a few paragraphs, pointers to additional information are provided.

Testing is a vital aspect of the upgrade process to ensure the reliability and correctness of your upgraded application. The guide provides information about how to best perform testing for upgraded applications. It describes potential upgrade strategies you can use and identifies the characteristics of applications and upgrade strategies that best fit each testing strategy. The testing processes and procedures for each strategy are detailed, as are the processes that are common to all testing strategies. It also lists some tools that can be used to facilitate testing.

Concepts and Features of the Visual Basic 6.0 Upgrade Assessment Tool

One of the key tasks of any upgrade project is to perform an assessment of the application to be upgraded to estimate the required cost and effort. This can be an extremely time-consuming task, particularly for very large projects that span many forms and modules. This can be further complicated by a lack of experience in having performed an upgrade to Visual Basic .NET; it's hard to estimate the effort that will be required if you do not have experience with what the issues are.

To alleviate some of the effort of assessment, the Visual Basic 6.0 Upgrade Assessment Tool has been developed. The purpose of this tool is to analyze your Visual Basic 6.0 projects to determine what issues you will need to address to be able to upgrade. It also provides information about where to get help understanding each issue and the types of skills needed to address them. The reports generated, in the form of Microsoft Excel worksheets, are configurable, so you can specify estimated costs for the different categories of issues. This helps to simplify the process of assessment by automating much of the work.

System Requirements

To apply the provided guidance and to use the assessment tool, you will need the following:

  • Microsoft Windows 2000, Windows XP Professional, or Windows Server 2003 operating system
  • Microsoft Visual Basic 6.0
  • Microsoft .NET Framework 1.1 (required)
  • Microsoft Visual Studio .NET development system (highly recommended, but not required)
  • Microsoft Excel 2003 (required to use the Visual Basic 6.0 Upgrade Assessment Tool)

Getting Started

It is recommended that you start by reading Chapter 1, "Introduction," starting with the section named "Why Consider an Upgrade Project?" This section helps you determine if an upgrade is the right choice for your project and provides a list of alternative approaches to software evolution. After determining that an upgrade is the right choice, you should continue by reading the section named "Functional Equivalence and Application Advancement" in Chapter 2, "Practices for Successful Upgrades," to get a very clear understanding of the scope of the guide. 

Community

This guidance offering, like many patterns & practices deliverables, is associated with a community site [Content link no longer available, original URL:http://practices.gotdotnet.com/projects/vb62vbnet]. On this community site, you can post questions, provide feedback, or connect with other users for sharing ideas. Community members can also help Microsoft plan and test future guidance offerings, and download additional content such as extensions and training material.

Future Plans

This guide and tool cover upgrades of Visual Basic 6.0 applications to Visual Basic .NET 2003 and Visual Basic 2005. At the time of this writing, there are no plans to create any new versions of this guide.

Feedback and Support

Questions? Comments? Suggestions? To provide feedback about this guide, or to get help with any problems, please visit the Visual Basic 6.0 to Visual Basic .NET Migration community site [Content link no longer available, original URL:https://www.gotdotnet.com/codegallery/codegallery.aspx?id=07c69750-9b49-4783-b0fc-94710433a66d]. The message board on the community site is the preferred feedback and support channel because it allows you to share your ideas, questions, and solutions with the entire community. Alternatively, you can send e-mail directly to the Microsoft patterns & practices team at devfdbck@microsoft.com, although we are unable to respond to every message.

Upgrading Visual Basic 6.0 Applications to Visual Basic .NET and Visual Basic 2005 is a guidance offering, designed to be reused, customized, and extended. It is not a Microsoft product. For more information, see the following table.

Attribute Description
Support Code based guidance is shipped "as is" and without warranties. Customers can obtain support through Microsoft Support Services for a fee, but the code is considered user-written by Microsoft support staff. The patterns & practices team works with product support and will assist them with escalations as needed. Customers are encouraged to support one another through online communities.
Functionality The guidance provides a flexible and architecturally sound solution to a common enterprise development challenge. The guidance addresses the challenges by using base platform features and adhering to best practices. The guidance is designed to be extended and customized by users.
Release Guidance releases are typically developed in a 3–6 month life cycle. Assets are released as they become ready on the currently available platform. New versions of existing assets (possibly revised to run on later versions of the platform) are released if there is sufficient customer demand.
Compatibility Code-based guidance is designed to help solve problems over specific versions of Microsoft products. As the products change, the guidance issued may change or become obsolete. When possible, guidance is developed with future releases in mind. There are no guarantees about compatibility with earlier releases of guidance, or with past or future platform releases. A phased migration strategy is recommended, and coexistence of multiple versions of the guidance is given high priority by the patterns & practices team.
Form factor Guidance is released as source code. Variability is provided through configuration and defined extensibility points, as well as through direct modification of the source code. Documentation focuses on how to use the asset, how to extend it, and the goals, patterns, and tradeoffs driving its design.

Authors and Contributors

The Upgrading Visual Basic 6.0 Applications to Visual Basic .NET and Visual Basic 2005 and the Visual Basic 6.0 Upgrade Assessment Tool were developed by the following individuals.

Principal Authors

The content for the guide and the accompanying assessment tool were developed by the following individuals at ArtinSoft:

  • Project Lead: Federico Zoufaly
  • Guidance: César Muñoz , Paul Dermody, Manfred Dahmen, Ronny Vargas, Hendel Valverde, José David Araya, Oscar Calvo, Allan Cantillo, Alvaro Rivera, Christian Saborío, Juan Fernando Peña, Xavier Morera, Iván Sanabria
  • Assessment tool development: Rolando Méndez

Contributors

The guide and assessment tool were produced with the help of the following people:

  • Program Manager: William Loeffler (Microsoft Corporation)
  • Product Manager: Eugenio Pace (Microsoft Corporation)
  • Architect: Keith Pleas (Guided Design)
  • Test: Edward Lafferty (Microsoft Corporation); Ashish Babbar, Terrence Cyril J., Manish Duggal, Chaitanya Bijwe, Arumugam Subramaniyam, Umashankar Murugesan, Dhanaraj Subbian, Tarin R. Shah, Dipika Khanna, Gayatri Patil, and Sandesh Pandurang Ambekar (Infosys Technologies Ltd)
  • Documentation and Samples: RoAnn Corbisier (Microsoft Corporation); Tina Burden McGrayne and Melissa Seymour (TinaTech Inc.); Sharon Smith (Linda Werner & Associates Inc); Francisco Fernandez and Paul Henry (Wadeware LLC)

Acknowledgements

Many thanks to the following individuals who provided invaluable assistance and feedback during the development of this guide:

  • Dan Appleman (Desaware Inc.)
  • Joe Binder (Microsoft Corporation)
  • Rob Copeland (Microsoft Corporation)
  • Jackie Goldstein (Renaissance Computer Systems Ltd.)
  • Ed Hickey (Microsoft Corporation)
  • Billy Hollis
  • Edward Jezierski (Microsoft Corporation)
  • Chris Kinsman (Vergent Software)
  • Deborah Kurata (InStep Technologies)
  • Julia Lerman (The Data Farm)
  • Rockford Lhotka (Magenic Technologies)
  • Christian Nielsen (Volvo Information Technology AB)
  • Jay Roxe (Microsoft Corporation)
  • Roberto Schatz (Microsoft Southcone)
  • Jay Schmelzer (Microsoft Corporation)
  • Arvindra Sehmi (Microsoft EMEA)
  • Scott Swigart (Swigart Consulting)
  • The Visual Basic MVPs (Microsoft Valued Professionals)
  • Gavin Warrener (Microsoft South Africa)

patterns & practices Developer Center

Visual Basic 6.0 Resource Center

ArtinSoft Web Site

Retired Content

This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This page may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.

patterns & practices Developer Center