Mega Code Archive

 
Categories / VB.Net Tutorial / Development
 

Finally after multiple catch statements

Module Module1     Sub Main()         Dim intItem1 As Integer = 0         Dim intItem2 As Integer = 128         Dim intResult As Integer         Try             intResult = intItem2 / intItem1         Catch e As OverflowException             Console.WriteLine("An overflow exception occurred.")         Catch e As OutOfMemoryException             Console.WriteLine("Out of memory.")         Catch e As IndexOutOfRangeException             Console.WriteLine("Array index out of range.")         Finally             Console.WriteLine("Finally")         End Try     End Sub End Module An overflow exception occurred. Finally