# 拿去用吧 (自行改良一下会比较好用)...

Posted by 安宝 on November 11, 1999 at 15:44:27:

In Reply to: 该如何取得 bit 值 ?????? posted by 月光仙子 on November 11, 1999 at 11:23:35:

Public Function AsctoBin(ByVal AscInt As Integer)As String
Dim I, J, k As Integer
Dim gsStr As String
Dim gnLen As Integer
Dim nData As Integer
nData = AscInt
gsStr = ""
I = -1
While I <> 0
I = Int(nData / 2)
J = nData Mod 2
gsStr = J & gsStr
nData = I
Wend
AsctoBin = gsStr
End Function

Follow Ups: