Advertisement
Neron7373

Untitled

Nov 20th, 2017
67
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.64 KB | None | 0 0
  1.         public void Test()
  2.         {
  3.             try
  4.             {
  5.                 M1();
  6.             }
  7.             catch (Exception ex)
  8.             {
  9.                 // Что сделать чтобы было: Исключение!
  10.                 ex.ToString();
  11.             }
  12.         }
  13.  
  14.         public void M1()
  15.         {
  16.             try
  17.             {
  18.                 throw new Exception("Исключение!");
  19.             }
  20.             catch (Exception e)
  21.             {
  22.                 throw;
  23.             }
  24.             finally
  25.             {
  26.                 int b = 0;
  27.                 int a = 2 / b;
  28.             }
  29.         }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement