The .NET Framework has a Math.DivRem , so if you really want to determine the dividend and balance at the same time:
Dim x As Integer = 12 Dim y As Integer = 5 Dim r As Integer Dim d As Integer = Math.DivRem(x, y, r) If r <> 0 Then ( do something ) End If
source share