c# multi exception catch code example
Example: two exceptions same catch c#
try
{
// Code
}
catch (Exception ex) when (ex is ArbitraryType1 || ex is ArbitraryType2)
{
throw;
}
try
{
// Code
}
catch (Exception ex) when (ex is ArbitraryType1 || ex is ArbitraryType2)
{
throw;
}