ASC(x$, n)
Purpose | To return the numeric value that is the ASCII code for the nth character of the string x$. If x$ is a null string, ASC(x$,n) returns value 0. n may start from 1 up to the length of the string. |
Examples | B = ASC("Test String",6) |
Comments: | B should contain the value 83 (which is ASCII value of 'S'). If n is less than 1 or greater than string length, ASC(x$, n) returns a 0. |
See Also | CHR$(n) |