Returns the numeric value that is the ASCII code for the first character of the passed string expression. The reverse of this process can be achieved using the Chr function.
Asc(string)
String - (Input, expression, Required)
Only the first character of this string expression is used. If an empty string, Null or Error is passed, then Error is returned
An integer number within the range of 0 to 255 (for non-DBCS systems) representing the ASCII code of the first character within the passed string.
Asc (“a”) |
Returns 97 |
Asc (“A”) |
Returns 65 |
Asc (“ABC”) |
Returns 65 |
Asc (“”) |
Returns Error |
Asc (Null) |
Returns Error |
Asc (Error) |
Returns Error |
Functions are specifically for use in the Macro Editor. Refer to Microsoft's official VB and JScript documentation for scripting equivalents.
Functions | Chr function | CSet function | Format function | InStr function | LCase function | Left function | Len function | LSet function | LTrim function | Mid function | Replace function | Right function | RSet function | RTrim function | Space function | String function | TCase function | Trim function | UBound function | UCase function
© 2004-2021 looksoftware. All rights reserved.