In a recent post response, it was posted in an email catch to use
What if it is not an SmtpException? Would it bomb the code?
Is this not contained in the catch(Exception ex) statement as well? i understand that it is a general exception, but it does throw the correct error to me if there is one.
Should we double catch?
Code:
catch(SmtpException exception)
{
Log.Error(exception);
}
What if it is not an SmtpException? Would it bomb the code?
Is this not contained in the catch(Exception ex) statement as well? i understand that it is a general exception, but it does throw the correct error to me if there is one.
Should we double catch?
Code:
catch(SmtpException exception)
{
Log.Error(exception);
}
catch(Exception generalExc)
{
Log.Error(generalExc);
}