-
-
0Private Declare Function GetVolumeInformation Lib "kernel32.dll" Alias _ "GetVolumeInformationA" (ByVal lpRootPathName As String, _ ByVa
-
2'text1 text2 command1 command2 Dim i As Integer Private Sub Command1_Click() '十进制转二进制 Dim IntI As Single Dim str As String IntI = Text1.Text '得到文本 Do While IntI <> 1 '如果不等于1就执行 str = CStr(IntI Mod 2) + str '除2取余数 IntI = Int(IntI / 2) '除2取整数 Loop str = CStr(IntI) + str '接上取后一个 Text2.Text = str '结果 End Sub Private Sub Command2_Click() '二进制转十进制 Dim str As Single For i = 0 To Len(Text2.Text) - 1 '测长度 '取第N位数*2的N次方相加 str = str + Mid(Text2.Text,