int a; try { int b; // a and b are accessible. } catch (Exception e) { int c; // a and c are accessible. } finally { int d; // a and d are accessible. }
using System; public class EmployeeListNotFoundException : Exception { public EmployeeListNotFoundException() { } public EmployeeListNotFoundException(string message) : base(message) { } public EmployeeListNotFoundException(string message, Exception inner) : base(message, inner) { } }