How to debug a native code Visual Basic Component in Visual C++ (166275)
The information in this article applies to:
- Microsoft Visual Basic Professional Edition for Windows 5.0
- Microsoft Visual Basic Professional Edition for Windows 6.0
- Microsoft Visual Basic Enterprise Edition for Windows 5.0
- Microsoft Visual Basic Enterprise Edition for Windows 6.0
This article was previously published under Q166275 SUMMARY
The Visual Basic 5.0 debugger allows you to debug your code at design time
before you compile it into an .exe, .dll, or .ocx. If you are debugging
Visual Basic-created COM components, you can debug them out-of-process by
running multiple projects in the same instance of Visual Basic 5.0, or by
running separate instances of Visual Basic 5.0 with the client running in
one and the COM component running in the other.
If you want to debug your components after they are compiled, you cannot
use the Visual Basic 5.0 debugger because it will only debug them at design
time. To debug a compiled Visual Basic component, you will need to use the
functionality of the Visual C++ 5.0 debugger. The following are situations
when you may need to debug a compiled Visual Basic component:
- if you are creating an ActiveX control for use in a container other
than Visual Basic 5.0.
- in an application execution environment such as Microsoft Transaction
Server where you are only allowed to run compiled .dlls.
- if you suspect your Visual Basic component is behaving differently at design time than it is compiled.
This article explains how to do this within the Microsoft Developer Studio
environment. You will need to have Visual Basic 5.0 and Visual C++ 5.0
installed on your development machine to follow this example.
Modification Type: | Minor | Last Reviewed: | 6/21/2006 |
---|
Keywords: | kbhowto kbusage KB166275 |
---|
|