Math.Max returns the larger of two 8-bit unsigned integers.
Class Sample Public Shared Sub Main() Dim xByte1 As Byte = 1 Dim xByte2 As Byte = 51 Console.WriteLine(Math.Max(xByte1, xByte2)) End Sub 'Main End Class 'Sample