.NET Array Dictionary List String Sub ArrayList Cast Class Console Dates DataTable DateTime Enum File For Format If IndexOf Lambda LINQ Nothing Parse Process Property Regex Replace Select Sort Split StringBuilder SubstringChr deals with Integers and Chars. You must convert your Integer into a Char in your VB.NET program. By using the Chr function, you can take an Integer that represents a specific character and then acquire the actual Char value.IntegerChar
VB.NET program that uses Chr function Module Module1 Sub Main() Dim c As Char = "x"c ' Input character. Dim i As Integer = Asc(c) ' Convert to ascii integer. Dim h As Char = Chr(i) ' Convert ascii integer to char. Console.WriteLine(c) Console.WriteLine(i) Console.WriteLine(h) End Sub End Module Output x 120 xThe letter "x". You can see that the ASCII representation for "x" is equal to 120. Then, the character representation (Chr) of 120 is equal to "x". So Asc and Chr can be used to reverse each other's effects on a value.
Tip: The Asc and Chr functions are not available in the C# language. They are only useful in VB.NET programs.
And: You can use Asc and Chr in these cases to simplify your program. More information on Val and Asc is available.Val and Asc Function Examples