Hi garyclarke-ga:
The Break into the debugger option is there just to identify the
particular statement that is causing that exception. It won't give you
the details of the exception.
For having details of the exception you need to have an exception
object, you have an exception object when you catch an exception for
example:
try
{
//write code that causes exception here
}
catch(Exception ex)
{
Debug.WriteLine(ex.InnerException, "Inner Message");
}
Here, once you break into the code you can use Step Into key (usually
F11) to step in the code, if there is a matching catch block it will
be encountered and there you can capture the inner property etc. using
Debug.WriteLine or Trace.WriteLine messages and any other logic that
suits your requirement.
So the point is, breaking into the code just identifies the line of
code causing the exception. To get the detail of exception, catch it
so that you have an exception object available and use the properties
of that object to get information about the exception.
I hope this helps,
SolidContent-ga |