Problem solve Get help with specific problems with your technologies, process and projects.

Debugging apps that use Visual Basic 6 and VB.NET

It's easy to create applications with bits and pieces of Visual Basic 6 and Visual Basic .NET. Maintaining code for these "hybrid" apps, though, requires a bit of extra care.

Given the popularity and ease of use of Visual Basic 6, it's little surprise that Microsoft makes it easy to build applications that use both Visual Basic 6 and Visual Basic .NET. Developers can write applications in VB .NET and bring legacy Visual Basic objects into the new app, or they can leave existing apps in VB 6 and call into the .NET Framework to take advantage of functionality not native to VB 6.

One concern that arises with these so-called "hybrid" applications is maintaining them.

More on VB 6 and VB.NET

Special Report: VB 6 to VB.NET Migration

Can VB 6 and VB.NET forms coexist?

Debugging is simple for applications written in a single language, but when VB 6 code is calling into VB.NET code, and vice versa, debugging gets a bit more complex. (No matter how complex, though, it is certainly not a process that should be deemphasized.)

A recent MSDN article by Scott Swigart addresses hybrid application debugging. It covers both VB .NET apps that use VB 6 components and VB 6 applications that use VB.NET components. As expected, both processes require a bit of switching between VB 6 and Visual Studio 2005 -- but it's a small price to pay for a bug-free application that offers the best of Visual Basic 6 and Visual Basic .NET.

Read "Debugging Hybrid Visual Basic 6.0/Visual Basic .NET Applications" on MSDN

Dig Deeper on .NET Framework security best practices

Start the conversation

Send me notifications when other members comment.

Please create a username to comment.