Debugger API

  • Thread starter Thread starter Mike McPhee
  • Start date Start date
M

Mike McPhee

is there a debugger API for .NET.

I need to be able to read a .net assembly for analysis and when I need to
report something about it
I need to point to the line of code when the .pdb file is present.

Is there a way to interace with .pdb files?
 
I think the System.Diagnostics.SymbolStore contains classes to read debug
information. AFAIK "real" debugging isn't possible from within the .net
framework - the framework provides COM interfaces for taht purpose that may
be accessed from C++. I really don't know much more than this, but the
cordbg command line debugger is available as a sample project in the "tool
developer's guide". Might be worth a look.

Niki
 
I found out that I can use the ISymWrapper but I can't seem to figure out
how to create an instance of
SymBinder. I saw that someone else had similar issues. See

http://groups.google.ca/[email protected]#link2

Someone from microsoft provided a "solution" which is

IMetaDataDispenser mdd =
(IMetaDataDispenser)Activator.CreateInstance(Type.GetTypeFromCLSID(
new Guid("e5cb7a31-7512-11d2-89ce-0080c792e5d8")));

Guid IID_IMetadataImport = new
Guid("7DAC8207-D3AE-4c75-9B67-92801A497D44");
IntPtr importer;
mdd.OpenScope(fn, 0, ref IID_IMetadataImport, out importer);but it
fails on me saying can't create interface.
 
Back
Top