Getting exception information.

  • Thread starter Thread starter Frank Rizzo
  • Start date Start date
F

Frank Rizzo

When I run my app in the IDE, dumping exception.ToString() information
to file usually gives me a very trace on what happened including line
numbers, which is really useful.

When I run the app outside the IDE (even though compiled for Debug), the
exception.ToString() doesn't seem to contain the line numbers where
the errors have occured. Is this by design? Is there a way to get line
numbers back? Am I missing something simple?
 
Frank Rizzo said:
[exception.ToString() omits line numbers outside IDE]

I think this depends on whether the *.pdb files (debugging symbols)
are available.

Have you tried StackFrame.GetFileLineNumber?

P.
 
Back
Top