Reputation: 33
I have three projects, One is a VB6 project which compiles to an EXE. Another is also a VB6 project, which compile to a DLL. And the last one is a .Net (2010) project which compiles to DLL.
The DLL from .Net is referenced in my VB6 DLL project. And the resulting VB6 DLL project is reference in my VB6 EXE project.
In this scenario, how can I debug my .Net DLL project?
It is failing (or not able to debug) in both cases, even if I attach the (VB6 DLL) process to my .Net DLL Project, or I setup the ‘start external program’ to my VB6 DLL project on .Net DLL Project.
Do I have to change the reference (.Net DLL) on my VB6 DLL Project to get it in debug?
All your valid inputs are welcome. (Please explain the procedures step by step which I need to do)
Thanks in advance.
Upvotes: 3
Views: 1647
Reputation: 1884
ah vb6 :) it's been a long time....
basically, you can't debug .NET code within VB6 IDE.
However, nothing stops you from creating a .NET test project to unit test the .NET dll. And that's what you should have done prior to reference it in VB6.
If you need to track down a specific issue, another way you can use is to write debugging infos to a file/database/event view/... when the dll is in debug mode, like which functions were called, parameters, stack trace...
Upvotes: 1
Reputation: 137148
You should be able to debug the C#.NET dll by setting the start action under Debug to
Start external program
and specify the VB6 executable as the program.
I know this works as I use this to debug a .NET/C# plugin for an old VB6 application.
It shouldn't matter how many other dlls (.NET or otherwise) you have to go through to get to the code you are trying to debug.
Upvotes: 1
Reputation: 21
This might not be correct, but I believe VB 2010 uses what? .NET 4.0, right? VB6 was created in like...1994 I believe, so it would be <= .NET 1.0. The binaries would more than likely be incompatible.
Upvotes: -4