Moving from VB6 to VB.NET
This mini-course presents the main issues, options and tools in moving from VB6 to VB.NET
What you'll learn
Visual Basic 9.0, hitting the scene in late 2007, is a sophisticated and mature programming language. Combined with the latest release of the .NET Framework and Visual Studio, the result is an incredibly powerful programming environment. This mini-course will start the VB6 developer down the path to VB.NET, presenting a variety of topics including tool support, porting options, thinking the "VB.NET-way" vs. the "VB6-way", and some of the major differences of VB.NET and .NET over VB6 and COM. Along the way, we'll see many VB6 and VB.NET coding examples involving GUIs, data access, classes, and OOP.
Table of contents
- Introduction 0m
- Module overview 1m
- 'This will only hurt a little bit' --- similarities between VB6 and VB.NET 1m
- The devil is in the details --- differences... 2m
- The good news --- transition help and benefits 2m
- Demo: a simple listbox app in VB6 1m
- Demo: equivalent listbox app in VB.NET 0m
- Demo: creating VB.NET project in Visual Studio 2008 1m
- Demo: creating the UI 1m
- Demo: programming Load event, compile, run 1m
- Demo: configuring button and programming Click event 2m
- Demo: With statement and VB.NET background compilation 2m
- Demo: VB.NET support for form resizing 2m
- Demo: summary of VB.NET listbox app 1m
- What's so different about VB.NET? 0m
- Major difference #1: a new run-time (CLR) 2m
- Major difference #2: compilation to platform-neutral assembly language (MSIL) 3m
- Major difference #3: a new component resolution algorithm (e.g. GAC) 4m
- Strategies for moving from VB6 to VB.NET 2m
- Overview of Microsoft's VB6 Upgrade Wizard (one possible strategy) 2m
- Demo: upgrade wizard example #1 of single-tier VB6 database app 2m
- Demo: running upgrade wizard 3m
- Demo: upgrade wizard's generated result 2m
- Demo: reviewing the upgrade report 2m
- Demo: warning, 'generated data access code may not scale' 1m
- Summary of upgrade wizard demo #1 1m
- Demo: upgrade wizard example #2 of MDI-based text editor 2m
- Demo: running the upgrade wizard 2m
- Demo: upgrade wizard's generated result 1m
- Demo: upgrade issue #1, dynamic binding 3m
- Demo: upgrade issue #2, dynamic vs. static binding 3m
- Demo: upgrade issue #3, the 'My.' productivity framework 2m
- Summary of upgrade wizard demo #2 1m
- Overview of Microsoft's Code Advisor for VB6 1m
- Demo: running Code Advisor for VB6 3m
- Overview of mixed-mode projects (another possible strategy) 1m
- Mixed-mode trade-offs 2m
- Our Training Goal 1m
- Resources 1m
- Summary 1m
- Questions? Email address and blog URL 0m
- Introduction 0m
- Module overview 0m
- Module subtext --- ways of thinking (VB6 vs .NET vs VB.NET) 1m
- Module examples --- overview 1m
- Example #1: Reading from a text file in VB6 1m
- Demo: example #1 in VB.NET --- 'the VB6 way' 4m
- Summary of example #1 'the VB6 way' 1m
- What's wrong with the 'VB6' way of writing VB.NET? 2m
- Again with example #1 in VB.NET --- this time 'the .NET way' 0m
- Exception handling with Try-Catch 2m
- Files and the StreamReader object 1m
- Proper close/cleanup with Using 1m
- Catching and Throwing exceptions 2m
- Summary of example #1 'the VB.NET way' 0m
- Again with example #1 in VB.NET --- this time 'the VB.NET way' 1m
- Example #2: a Product class in VB6 1m
- Using a VB6 class 1m
- Motivating VB.NET changes to Product class 0m
- Real constructors! 1m
- Garbage collection instead of reference counting! 1m
- Demo: Product class in VB.NET 3m
- Demo: using Product class in VB.NET 3m
- Summary of Product Class in VB.NET 2m
- Class Properties in VB6 1m
- Demo: Class Properties in VB.NET 4m
- Summary of Class Properties in VB.NET 1m
- Example #3: data access in VB6 3m
- Example #3 in VB.NET --- 'the VB6 way' 2m
- Again example #3 in VB.NET --- this time 'the .NET way' 0m
- DataSets == disconnected recordsets 1m
- Factory pattern for database-neutral, reusable code 4m
- Collection vs Dictionary 1m
- Generics! 2m
- Working with DataSets 2m
- Demo: working with DataSets 4m
- Working with Factory objects, filling DataSets 1m
- Demo: Factory objects and Filling DataSets 6m
- Summary of Factory objects and filling DataSets 0m
- Resources 1m
- Summary 2m
- Questions? Email address, blog URL 0m