Board logo

标题: [技术讨论] 自制可打印字符ansi编码表 [打印本页]

作者: batman    时间: 2011-5-24 02:27     标题: 自制可打印字符ansi编码表

  1. Set fso = CreateObject("scripting.filesystemobject")
  2. myarray = Array("0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f")
  3. vbstr = "编码(10)" & Chr(9) & "编码(16)" & Chr(9) & "字符" & vbCrLf
  4. vbstr = vbstr & "8" & Chr(9) & "0x08" & Chr(9) & "[" & Chr(8) & "]" & vbCrLf
  5. vbstr = vbstr & "9" & Chr(9) & "0x09" & Chr(9) & "[" & Chr(9) & "]" & vbCrLf
  6. For i = 32 To 126
  7.   a = myarray(Int(i / 16)): b = myarray(i - a * 16)
  8.   vbstr = vbstr & i & Chr(9) & "0x" & a & b & Chr(9) & "[" & Chr(i) & "]" & vbCrLf
  9. Next
  10. fso.OpenTextFile("ansi.txt", 2, 1).Write vbstr
  11. Set fso = Nothing
复制代码

作者: ppmath    时间: 2011-5-24 08:12

不知怎么用,。。。。
作者: batman    时间: 2011-5-24 16:56

知道看生成的ansi.txt就可以了
作者: zz100001    时间: 2011-5-24 17:51

vbstr = vbstr & Right(1000 + i, 3) & vbTab & "0x" & Hex(i) & vbTab & "[" & Chr(i) & "]" & vbCrLf
作者: wankoilz    时间: 2011-5-26 13:20

Right(1000 + i, 3)
这样也行啊...




欢迎光临 批处理之家 (http://bbs.bathome.net/) Powered by Discuz! 7.2