[Solved] Which ascii code is this symbol? [closed]


In VBA, there is the AscW function that returns the Unicode code point for the first letter of a string as a decimal number.

Use the following code snippet as an example:

Sub mycode()
    MsgBox "female symbol code = " & CStr(AscW(Cells(1, 1).Text)) & ", male symbol code = " & CStr(AscW(Cells(2, 1).Text))
End Sub

Output will be

female symbol code = 9792, male symbol code = 9794

Enter the respective symbols in the Cells A1, A2 of the active Worksheet before running that code in the vba editor. You enter these symbols by keeping Alt pressed while typing 11 and 12, resp.

NB

There is (at least) one 8-bit codepage that supports the male and female gender symbols ( U+2642 and U+2640, resp. ) as chr(11) and chr(12), resp.: code page 437.

This seems to be the closest you can get to an ascii representation.

1

solved Which ascii code is this symbol? [closed]