Attaching debugger remotely?

B

Brett Romero

I have an application throwing an exception when it starts. I catch
the exception and write this to the event log. The app continues and
completes loading. But now, of course, it doesn't function properly.
For some reason, there isn't an included line number in the exception.
The exception gives the class and method plus that it's a null
reference but no line number.

The app is on MachineB (no VS.NET) and I'd like to attach remotely from
MachineA (VS.NET) to debug it. The problem is the exception will have
already thrown by the time I find the process and attach. I need to
attach before any code executes. I could rebuild the EXE to display a
message box first thing. This would load the process but stop code from
executing until I attach.

Any suggestions?

Thanks,
Brett
 
C

Cor Ligthert [MVP]

Brett,

The first thing you should not never do in my opinion.
I have an application throwing an exception when it starts. I catch
the exception and write this to the event log.

It does not solve anything, you only create a for sure problem in future
with that.

Therefore in my idea, just try to debug it on machine A first. In the way
you want to do it, it cost you for sure 100 times more time than needed.

Just my idea.

Cor
 
B

Brett Romero

Therefore in my idea, just try to debug it on machine A first.

The exception does not occur on machineA.

Brett
 
C

Cor Ligthert [MVP]

Brett,

Should you than not first investigate the differences.

Used DLLs, type of OS, dotNet versions and than if you don't see it, throw
that in this newsgroup or in the newsgroups

microsoft.public.dotnet.framework
or
microsoft.public.dotnet.general

Although I have the idea that with that information you will get more
responses in this newsgroup because of the fact that it has more visitors.

Cor
 

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