By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
445,909 Members | 2,008 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 445,909 IT Pros & Developers. It's quick & easy.

How To: Debug a .NET DLL ?

P: n/a
I've created several DLL's that I use in other projects. I "Add Reference"
to these other projects pointing to my DLL. Probelm is, I can't seem to be
able to step into my DLL code (from these other projects) -- I've tried
adding the source code project (that was used to build the DLL) into my
current solution, but I still can't seem to step into the code of my DLL.

Any suggestion?

I must be missing something simple?

Thanks, Rob.
Nov 21 '05 #1
Share this Question
Share on Google+
4 Replies


P: n/a
In article <u1**************@TK2MSFTNGP10.phx.gbl>, ro*****@pacbell.net
says...
I've created several DLL's that I use in other projects. I "Add Reference"
to these other projects pointing to my DLL. Probelm is, I can't seem to be
able to step into my DLL code (from these other projects) -- I've tried
adding the source code project (that was used to build the DLL) into my
current solution, but I still can't seem to step into the code of my DLL.

Any suggestion?


Are the other DLL's compiled in debug mode?

Does the PDB file that gets generated during a debug compile exist in
the same directory as the DLL?

--
Patrick Steele
Microsoft .NET MVP
http://weblogs.asp.net/psteele
Nov 21 '05 #2

P: n/a
Patrick,

Yes and Yes.

I assume that I am supposed to add the DLL source code project/assembly to
my primary solution? Is there anything else I need to do?

In my case:

I have a Windows Service, that references a couple of other DLL's I created.
I have no problem debugging my Windows Service solution (i.e. using Debug
Process, select the running service, attach, etc.), but no matter what I do,
I can't seem to step into the DLL code that is called from my Windows
Service.

Do I need to resort to other methods as it seems debugging DLL's in a
Windows Service is just not supported?

I'll code a Windows Form app to test the DLL and see if this is just an
issue with DLLs in Windows Services -- it shouldn't be, but...

Rob.

"Patrick Steele [MVP]" <pa*****@mvps.org> wrote in message
news:MP************************@msnews.microsoft.c om...
In article <u1**************@TK2MSFTNGP10.phx.gbl>, ro*****@pacbell.net
says...
I've created several DLL's that I use in other projects. I "Add
Reference"
to these other projects pointing to my DLL. Probelm is, I can't seem to
be
able to step into my DLL code (from these other projects) -- I've tried
adding the source code project (that was used to build the DLL) into my
current solution, but I still can't seem to step into the code of my DLL.

Any suggestion?


Are the other DLL's compiled in debug mode?

Does the PDB file that gets generated during a debug compile exist in
the same directory as the DLL?

--
Patrick Steele
Microsoft .NET MVP
http://weblogs.asp.net/psteele

Nov 21 '05 #3

P: n/a
Update:

I ran a test project (standard Windows Form) loading the my DLL (Add
Reference) and loaded the DLL source code project -- this worked, I could
step into the DLL code.

So, it appears that stepping into DLL code via a Windows Service project
using the Debug Processes is just not supported. Unless someone has some
insights that I'm missing?

Rob.

"Rob R. Ainscough" <ro*****@pacbell.net> wrote in message
news:uv**************@TK2MSFTNGP09.phx.gbl...
Patrick,

Yes and Yes.

I assume that I am supposed to add the DLL source code project/assembly to
my primary solution? Is there anything else I need to do?

In my case:

I have a Windows Service, that references a couple of other DLL's I
created. I have no problem debugging my Windows Service solution (i.e.
using Debug Process, select the running service, attach, etc.), but no
matter what I do, I can't seem to step into the DLL code that is called
from my Windows Service.

Do I need to resort to other methods as it seems debugging DLL's in a
Windows Service is just not supported?

I'll code a Windows Form app to test the DLL and see if this is just an
issue with DLLs in Windows Services -- it shouldn't be, but...

Rob.

"Patrick Steele [MVP]" <pa*****@mvps.org> wrote in message
news:MP************************@msnews.microsoft.c om...
In article <u1**************@TK2MSFTNGP10.phx.gbl>, ro*****@pacbell.net
says...
I've created several DLL's that I use in other projects. I "Add
Reference"
to these other projects pointing to my DLL. Probelm is, I can't seem to
be
able to step into my DLL code (from these other projects) -- I've tried
adding the source code project (that was used to build the DLL) into my
current solution, but I still can't seem to step into the code of my
DLL.

Any suggestion?


Are the other DLL's compiled in debug mode?

Does the PDB file that gets generated during a debug compile exist in
the same directory as the DLL?

--
Patrick Steele
Microsoft .NET MVP
http://weblogs.asp.net/psteele


Nov 21 '05 #4

P: n/a
In article <uv**************@TK2MSFTNGP09.phx.gbl>, ro*****@pacbell.net
says...
I have a Windows Service, that references a couple of other DLL's I created.
I have no problem debugging my Windows Service solution (i.e. using Debug
Process, select the running service, attach, etc.), but no matter what I do,
I can't seem to step into the DLL code that is called from my Windows
Service.


Where is this DLL located? In the GAC?

--
Patrick Steele
Microsoft .NET MVP
http://weblogs.asp.net/psteele
Nov 21 '05 #5

This discussion thread is closed

Replies have been disabled for this discussion.