What is the alternative to AscW in VB.NET

1 Answer

0 votes
Imports System

' Convert.ToInt32

Module Program
    Sub Main()
		Dim ch As Char = "A"c ' Unicode/ASCII value for "A" = 65

        ' Alternative without AscW
        Dim code2 As Integer = Convert.ToInt32(ch) ' AscW(ch)

        Console.WriteLine($"Convert.ToInt32: {code2}")
    End Sub
End Module


				
' run:
'
' Convert.ToInt32: 65
'

 



answered Nov 10 by avibootz

Related questions

1 answer 26 views
1 answer 69 views
1 answer 43 views
1 answer 45 views
1 answer 148 views
...