代码如下。拦姿桥
以下假设要转换的都是19XX年出生册伏的。
Dim Weight(17) As Integer
Dim CheckCode As String
Private Sub Command1_Click()
Dim i As Integer
Dim OldID As String, NewID As String
Dim Position As Integer
OldID = Left(Text1.Text, 6) &"19" &Right(Text1.Text, 9)
For i = 1 To 17
Position = Position + Val(Mid(OldID, i, 1)) * Weight(i)
Next i
Position = Position Mod 11
NewID = OldID &Mid(CheckCode, Position + 1, 1)
Text2.Text = NewID
End Sub
Private Sub Form_Load()
Weight(1) = 7
Weight(2) = 9
Weight(3) = 10
Weight(4) = 5
Weight(5) = 8
Weight(6) = 4
Weight(7) = 2
Weight(8) = 1
Weight(9) = 6
Weight(10) = 3
Weight(11) = 7
Weight(12) = 9
Weight(13) = 10
Weight(14) = 5
Weight(15) = 8
Weight(16) = 4
Weight(17) = 2
CheckCode = "10X98765432"
End Sub
CACDABDABC
B
MsgBox
Val Str/Cstr
frm vbp
判断读取文件是否结尾
21
一.
6 i "*"
二.
0 100 i+1
三.
Dim a1 As Single,a2 As Single,a3 As Single
a2=(64-6*y)+3*x
Print a1+a3
四.
a=1
For i=1 to 7
Print a
五.
s=0
For i=1 to 100 Step 2
s=s+i
六.
cj>=60
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)