L
Lloyd Dupont
SqlExeption.Message is not override in CF.
I have a SqlException happening in my code
I treat it in a Global method:
OnException(Exception e)
{
string s = e.Message;
}
the message is "SqlException"
however if I cast my exception to SqlException
I have
OnException(Exeption e)
{
string s = e.Message;
if(e is SqlException)
s = ((SqlException) e).Message;
}
in this case I have a different message like "INSERT statement conflict
....."
so it seems that the Message method has not been correctly been overwrite
(with the overwrite keyword)
I have a SqlException happening in my code
I treat it in a Global method:
OnException(Exception e)
{
string s = e.Message;
}
the message is "SqlException"
however if I cast my exception to SqlException
I have
OnException(Exeption e)
{
string s = e.Message;
if(e is SqlException)
s = ((SqlException) e).Message;
}
in this case I have a different message like "INSERT statement conflict
....."
so it seems that the Message method has not been correctly been overwrite
(with the overwrite keyword)