TA的每日心情 | 慵懒 2023-10-14 18:34 |
---|
签到天数: 210 天 [LV.7]常住居民III
|
发表于 2020-3-16 08:39:58
|
显示全部楼层
本帖最后由 deeke 于 2020-3-16 08:43 编辑 . P7 B1 x) m+ M! V5 W! Z6 u
F( Y( P+ B( q8 f) @( P" k1. 试试 MsgBox % SubStr("123abc我在哪儿789", 7, 1); 应该显示 "我"。
, T8 h; K# c, \* W; Q; U$ U( p
4 \, R, b2 p! G9 x( Q6 y0 |2. Asc() returns a numeric value in the range 0 to 255 (for ANSI) or 0 to 0xFFFF (for Unicode).0 [/ B, Z& Y$ p$ v
试试 MsgBox, % Asc("我");
; O7 k; Y& W% J& c3 J0 k
0 j6 d* `9 g/ p2 T) Q3. Ord() returns a numeric value in the range 0 to 255 (for ANSI) or 0 to 0xFFFF (for Unicode) or 0x10000 to 0x10FFFF (for the corresponding Unicode character)., c% m, O9 v+ ]- E. [
Apart from the Unicode supplementary character detection, Ord() is identical to Asc().0 _, F- w3 @1 S+ l/ y' s6 ~2 h
试试 MsgBox, % Ord("我") ;5 |5 Z e" ~! R; u& M# x
+ R; w4 w7 r6 u9 ^4. "code > 127" 表示所有的编码后超过1字节的字符,比如希腊字母、中日韩文字。 |
|