题型:综合题 题类:常考题 难易度:普通
浙江省高中信息技术——VB基础知识
Private Sub Command1_ Click( )
Dimi As Integer, n As Integer, dec As Integer
Dim ch As String, s As String
dec=0
①
For i= 1 To Len(s)
ch= Mid(s, i, 1)
If ② Then
n Asc (ch)-Asc (“A”) +10
Else
n Val(Mid(s, i, 1))
End If
dec = dec +n * 16 ^ (Len (s)-i)
Next i
Text2. Text = Str(dec)
End Sub
① ②
试题篮