best way to debug a dll in c# free edition

M

Marc Gravell

OK - just so I understand your intended architecture... what is the
problem in using a project-reference between the two (in the same
solution, supported in Express Edition), with the form referencing the
dll... you can then just hit "play", and use break-points as normal.
This still loads from the HDD...

Or are you essentially trying to debug this as a plug-in module (i.e.
not referenced at compile-time)?

Marc
 
P

Peted

Hello,

im producing an aplication in 2 parts.

1. is the main exe runtime of the application that is a mdi form with
controls

2. the second part is a dll that essential is made up of form classes



the main exe is designed to load the dll from a directory, and creat
new instances of the child forms in the dll for use in the mdi form
application


Whats the best way to debug this dll in conjuction with the main
calling exe using the free edition of c# 2005

currently i have 2 seperate projects, i make a chnage to the dll,
compy it to the correct directory then load and run the call
application to test it.

Is there a way to do this easier ? keeping in mind the calling exe
wants to load the dll from HDD


andy advice appreciated


thanks
 
P

Peted

Or are you essentially trying to debug this as a plug-in module (i.e.
not referenced at compile-time)?

Marc
this is correct, the main application when finished will be static,
the dll "plugin" if you will will be updated in perpetuity, with new
form interfaces (that are all unique), and distributed to uses when
updates occur.

so people only have to download and update the dll plugin file.

I have succesfully used reflection to load the dll from HDD and
instantiate it as child forms in the main app, but i want an easier
way to develop/debug exisitng and new form interfaces, as opposed to

"create" dll
copy to directory
run apllication
test for errors
go back to dll project
edit etc etc etc etc

any advice appreciated


thanks
 
C

Chris Dunaway

the dll "plugin" if you will will be updated in perpetuity, with new
form interfaces (that are all unique), and distributed to uses when
updates occur.

so people only have to download and update the dll plugin file.

I have succesfully used reflection to load the dll from HDD and
instantiate it as child forms in the main app, but i want an easier
way to develop/debug exisitng and new form interfaces, as opposed to

You can load up the dll project in a separate instance of VS, then
attach the debugger to the running .exe and set your breakpoints.
 
P

Peted

It seems the ability to attache the debugger to a running instance of
the exe is not available in the c# express edition.

In addition to that when the main program runs it looks for the dll to
load, but it cant of course becasue it dont exist untill it is built
from the dll project.

Sort of a chicken and egg situation

Peted
 
C

Chris Dunaway

It seems the ability to attache the debugger to a running instance of
the exe is not available in the c# express edition.
Bummer


In addition to that when the main program runs it looks for the dll to
load, but it cant of course becasue it dont exist untill it is built
from the dll project.

Does the main program reference the .dll directly? In that case you
should use an interface and have each .dll that is written implement
the interface. Then the main program can be de-coupled from
the .dll's. You then just give the interface to the .dll writers and
as long as they implement it correctly, your program will be able to
use the .dll's.

Here is a post I made awhile back with a little more detail:

http://tinyurl.com/2sshw5

Hope this helps
 
P

Peted

thanks

i will have a look at it


Does the main program reference the .dll directly? In that case you
should use an interface and have each .dll that is written implement
the interface. Then the main program can be de-coupled from
the .dll's. You then just give the interface to the .dll writers and
as long as they implement it correctly, your program will be able to
use the .dll's.

Here is a post I made awhile back with a little more detail:

http://tinyurl.com/2sshw5

Hope this helps
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top