How to convert binary string to integer in VB.NET

1 Answer

0 votes
Imports System

Class Program
    Public Shared Sub Main(ByVal args As String())
        Dim binary As String = "1011001011"
		
        Dim n As Integer = Convert.ToInt32(binary, 2)
		
        Console.WriteLine(n)
    End Sub
End Class


' run:
'
' 715
'

 



answered Jul 18, 2025 by avibootz
...