ASCII code tables and characters in C # conversion methods.

Source: Internet
Author: User
ASCII code tables and characters in C # conversion methods.

Table of ASCII Characters

This table lists the ASCII characters and their decimal, octal and hexadecimal numbers. Characters which appear as names in parentheses (e.g., (NL)) are non-printing. A table of the common non-printing characters appears after this table.

Char Dec Oct Hex | Char Dec Oct Hex | Char Dec Oct Hex | Char Dec Oct Hex-------------------------------------------------------------------------------------(nul) 0 0000 0 x00 | (sp) 0040 0x20 | @ 0100 0x40 |      ' 0140 0x60 (SOH) 1 0001 0x01 |! 0041 0x21 | A 0101 0x41 | A 0141 0x61 (STX) 2 0002 0x02 | "0042 0x22 | B 0102 0x42 | B-0142 0x62 (ETX) 3 0003 0x03 | # 0043 0x23 | C 0103 0x43 | C-0143 0x63 (EOT) 4 0004 0x04 | $0044 0x24 | D 0104 0x44 | D-0144 0x64 (ENQ) 5 0005 0x05 | % Notoginseng 0045 0x25 | E-0105 0x45 | E-0145 0x65 (ACK) 6 0006 0x06 | & 0046 0x26 | F 0106 0x46 | F 102 0146 0x66 (BEL) 7 0007 0x07 | ' 0047 0x27 | G 0107 0x47 | G-0147 0x67 (BS) 8 0010 0x08 | (0050 0x28 | H-0110 0x48 | H-0150 0x68 (HT) 9 0011 0x09 | ) 0051 0x29 |     I 0111 0x49 | I 0151 0x69 (NL) 0012 0x0a | * 0052 0x2a | J-0112 0x4a | J. 0152 0X6A (VT) 0013 0x0b | + 0053 0x2b | K-0113 0x4b | K-0153 0x6b (NP) 0014 0x0c | , 0054 0x2c | L-0114 0x4c | L 108 0154 0x6c (CR) 0015 0x0d | -0055 0x2d | M-0115 0x4d |      M 109 0155 0x6d (SO) 0016 0x0e |. 0056 0x2e | N 0116 0x4e | n 0156 0x6e (si) 0017 0x0f | /0057 0x2f | O-0117 0x4f | o 0157 0x6f (dle) 0020 0x10 | 0 0060 0x30 | P-0120 0x50 | P 112 0160 0x70 (DC1) 0021 0x11 | 1 0061 0x31 | Q Bayi 0121 0x51 | Q 113 0161 0x71 (DC2) 0022 0x12 | 2 0062 0x32 | R-0122 0x52 | R 114 0162 0x72 (DC3) 0023 0x13 | 3 Wuyi 0063 0x33 | S-0123 0x53 | S-0163 0x73 (DC4) 0024 0x14 | 4 0064 0x34 | T-0124 0x54 | T 116 0164 0x74 (NAK) 0025 0x15 | 5 0065 0x35 | U-0125 0x55 | U 117 0165 0x75 (SYN) 0026 0x16 | 6 0066 0x36 | V 0126 0x56 | V 118 0166 0x76 (ETB) 0027 0x17 | 7 0067 0x37 | W-0127 0x57 | W 119 0167 0x77 (CAN) 0030 0x18 | 8 0070 0x38 | X-0130 0x58 | X-0170 0x78 (EM) 0031 0x19 | 9 0071 0x39 | Y-0131 0x59 | Y 121 0171 0x79 (sub) 0032 0x1a | : 0072 0x3a | Z 0132 0x5a |      Z 122 0172 0x7a (ESC) 0033 0x1b |; 0073 0x3b | [0133 0x5b |        {123 0173 0x7b (FS) 0034 0x1c | 0076 0x3e | ^ 0136 0x5e |      ~ 126 0176 0x7e (US) to 0037 0x1f |? 0077 0x3f | _ 0137 0x5f | (DEL) 127 0177 0x7f
												
The above is an ASCII table. Used to be found in the past. These are included for future reference. In C # you want to get an ASCII value for a character, you can do this:
char s = char.parse ("s");
int i = (int) s;

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.