I have one computer where .NET exceptions cannot be caught in the
debugger, and not constructed correctly. All system exceptions are
reported as "System.Interop.SEHException - an external component has
thrown an exception". Have not tried throwing exceptions derived from
ApplicatinoException yet.
I reinstalled .NET and Visual Studio, all to no avail. Reinstalling
this particular machine from scratch is not an option, unfortunately.
For example, this code will produce this behavior:
XslTranform x;
...
x.Load ("badxslfile.xsl");
When run without the debugger, there is a stack printout at the console,
and SEHException is on top of the stack. Debugger also reports it as
SEHException.
However, the exceptions are correctly caught by catch () { } blocks:
try
{
x.Load ("badxslfile.xsl");
}
catch (XsltCompileException ex)
{
. . .
/* Breakpoint */
}
When I examine the ex variable in debugger on the above breakpoint,
the string returned from ex.Message is corrupt:
(2, 4): [][][]
where [] stands for a "hollow square" symbol, perhaps displayed
by the debugger in lieu of unprintable characters.
Any help out there?
-kkm
You can read messages from the DOTNET archive, unsubscribe from DOTNET, or
subscribe to other DevelopMentor lists at http://discuss.develop.com.