Re: Debugging DLMs [message #48356] |
Thu, 13 April 2006 12:07 |
Haje Korth
Messages: 651 Registered: May 1997
|
Senior Member |
|
|
Hi,
I do not experience any such problem and I have been moving from IDL 6.1 to
6.2 to 6.3 and have compiled codes with VS 2003 and 2005. So I cannot
explain the behavior assuming that you have closely followed Ronn's
directions. For me there is no need to manually load the DLM. The DLM is
automatically loaded when a command from the DLM is invoked. So the break
point really can't kick in before the DLM is loaded, right?
With VS 2005 I do get occasional crashes of the VS devenv when using
breakpoint. It does not happen immediately at a breakpoint or when stepping
through the code. Sometimes the devenv is not touched for minutes when it
suddenly disappears. No error message, no debug message, devenv simply
disappears. Not sure who to blame for this. Could be anywhere between a VS
bug or the beta FORTRAN compiler I am using in my code, or the fact that IDL
is probably developed on VS version <2005. But I am not even going to try to
solve this issue. Microsoft will blame it on Intel and vice versa. In the
end they will both tell me RSI has a problem in their API.
Cheers,
Haje
<codepod@gmail.com> wrote in message
news:1144952727.433163.96520@j33g2000cwa.googlegroups.com...
> Gareth,
>
> What is happening is since the DLM library (DLL) isn't loaded into the
> process space until IDL actually uses it, the debugger isn't aware of
> its contents and disables the breakpoint.
>
> To get around this you can just load the DLM manually using DLM_LOAD
> after you start IDL. This will load the DLL into the process space and
> provide the debugger with the information it needs. At this point you
> can either enable your breakpoints and/or add new ones.
>
> This is very irritating in Visual Studio and I've been bitten by it on
> more than one occasion. The above solution should get you on your way.
>
> Cheers,
> -CP
>
>
>
>
> gareth.price@physics.cr.man.ac.uk wrote:
>> Hi there,
>>
>> I've been using a few DLMs that I wrote (with the guidance of Ronn
>> Kling's "Calling C from IDL" book) for a while now with excellent
>> results. However I've recently noticed an error I want to debug and
>> have been unable to get the Visual C++ .NET debugger to work, despite
>> the fact that it used to work fine when I originally wrote the code
>> (using the method described in appendix C of the book).
>>
>> The breakpoints are fine until IDL is started when they drop out as "No
>> executable code is currently loaded at this location". The only change
>> I can possibly think of is that I've changed from IDL 6.1 to 6.2, but
>> I've altered this in all the relevent parts of the VC++ project
>> properties.
>>
>> I'm not particularly experienced with the VC++ compiler but don't think
>> I've done anything stupid. Has anyone else had this problem and know
>> what I'm doing wrong, I'm a bit stuck?
>>
>> Cheers, Gareth Price
>
|
|
|
Re: Debugging DLMs [message #48359 is a reply to message #48356] |
Thu, 13 April 2006 11:25  |
codepod
Messages: 19 Registered: March 2006
|
Junior Member |
|
|
Gareth,
What is happening is since the DLM library (DLL) isn't loaded into the
process space until IDL actually uses it, the debugger isn't aware of
its contents and disables the breakpoint.
To get around this you can just load the DLM manually using DLM_LOAD
after you start IDL. This will load the DLL into the process space and
provide the debugger with the information it needs. At this point you
can either enable your breakpoints and/or add new ones.
This is very irritating in Visual Studio and I've been bitten by it on
more than one occasion. The above solution should get you on your way.
Cheers,
-CP
gareth.price@physics.cr.man.ac.uk wrote:
> Hi there,
>
> I've been using a few DLMs that I wrote (with the guidance of Ronn
> Kling's "Calling C from IDL" book) for a while now with excellent
> results. However I've recently noticed an error I want to debug and
> have been unable to get the Visual C++ .NET debugger to work, despite
> the fact that it used to work fine when I originally wrote the code
> (using the method described in appendix C of the book).
>
> The breakpoints are fine until IDL is started when they drop out as "No
> executable code is currently loaded at this location". The only change
> I can possibly think of is that I've changed from IDL 6.1 to 6.2, but
> I've altered this in all the relevent parts of the VC++ project
> properties.
>
> I'm not particularly experienced with the VC++ compiler but don't think
> I've done anything stupid. Has anyone else had this problem and know
> what I'm doing wrong, I'm a bit stuck?
>
> Cheers, Gareth Price
|
|
|