首页 > Web开发 > 详细

bytes2BSTR

时间:2016-02-08 22:24:27      阅读:118      评论:0      收藏:0      [点我收藏+]

复制代码 代码如下:

Function bytes2BSTR(vIn) 
 strReturn = "" 
 For i = 1 To LenB(vIn) 
 ThisCharCode = AscB(MidB(vIn,i,1)) 
 If ThisCharCode < &H80 Then 
 strReturn = strReturn & Chr(ThisCharCode) 
 Else 
 NextCharCode = AscB(MidB(vIn,i+1,1)) 
 strReturn = strReturn & Chr(CLng(ThisCharCode) * &H100 + CInt(NextCharCode)) 
 i = i + 1 
 End If 
 Next 
 bytes2BSTR = strReturn 
End Function  

bytes2BSTR

原文:http://www.jb51.net/article/6521.htm

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!