英语翻译Sub capt(ii As Integer)S = "asdfghjklqwertyuiopzxcvbnm12
来源:学生作业帮 编辑:作业帮 分类:综合作业 时间:2024/10/04 17:07:52
英语翻译
Sub capt(ii As Integer)
S = "asdfghjklqwertyuiopzxcvbnm1234567890"
If (ii = 5) Then
For i = 0 To 4
i2 = Int(Rnd(Len(S) - 1) * Len(S) + 1)
ss = Mid(S,i2,1)
Label1(i).Caption = ss
Next i
Else
i3 = Int(Rnd(Len(S) - 1) * Len(S) + 1)
ss = Mid(S,i3,1)
Label1(ii).Caption = ss
End If
End Sub
Private Sub Command1_Click()
If Command1.Caption = "停止" Then
Command1.Caption = "继续"
Timer2.Enabled = False
Else
Command1.Caption = "停止"
Timer2.Enabled = True
End If
End Sub
Private Sub Command1_KeyDown(KeyCode As Integer,Shift As Integer)
For i = 0 To 4
If LCase(Trim(Label1(i).Caption)) = LCase(Chr(KeyCode)) Then
j = Int(Rnd(Form1.Width) * Form1.Width + 1)
Label1(i).Top = 0
Label1(i).Width = j
capt (i)
Label2.Caption = Int(Label2.Caption) + 1
End If
Next i
End Sub
Private Sub Form_KeyDown(KeyCode As Integer,Shift As Integer)
For i = 0 To 4
If LCase(Trim(Label1(i).Caption)) = LCase(Chr(KeyCode)) Then
j = Int(Rnd(Form1.Width) * Form1.Width + 1)
Label1(i).Top = 0
Label1(i).Width = j
capt (i)
Label2.Caption = Int(Label2.Caption) + 1
End If
Next i
End Sub
Private Sub Form_Load()
capt (5)
End Sub
Private Sub Timer2_Timer()
For i = 0 To 4
Label1(i).Top = Label1(i).Top + 100
If (Label1(i).Top >= Form1.Height) Then
j = Int(Rnd(Form1.Width) * Form1.Width + 1)
Label1(i).Top = 0
Label1(i).Width = j
capt (i)
End If
Next i
End Sub
---------------------------------
高手来下哈...
Sub capt(ii As Integer)
S = "asdfghjklqwertyuiopzxcvbnm1234567890"
If (ii = 5) Then
For i = 0 To 4
i2 = Int(Rnd(Len(S) - 1) * Len(S) + 1)
ss = Mid(S,i2,1)
Label1(i).Caption = ss
Next i
Else
i3 = Int(Rnd(Len(S) - 1) * Len(S) + 1)
ss = Mid(S,i3,1)
Label1(ii).Caption = ss
End If
End Sub
Private Sub Command1_Click()
If Command1.Caption = "停止" Then
Command1.Caption = "继续"
Timer2.Enabled = False
Else
Command1.Caption = "停止"
Timer2.Enabled = True
End If
End Sub
Private Sub Command1_KeyDown(KeyCode As Integer,Shift As Integer)
For i = 0 To 4
If LCase(Trim(Label1(i).Caption)) = LCase(Chr(KeyCode)) Then
j = Int(Rnd(Form1.Width) * Form1.Width + 1)
Label1(i).Top = 0
Label1(i).Width = j
capt (i)
Label2.Caption = Int(Label2.Caption) + 1
End If
Next i
End Sub
Private Sub Form_KeyDown(KeyCode As Integer,Shift As Integer)
For i = 0 To 4
If LCase(Trim(Label1(i).Caption)) = LCase(Chr(KeyCode)) Then
j = Int(Rnd(Form1.Width) * Form1.Width + 1)
Label1(i).Top = 0
Label1(i).Width = j
capt (i)
Label2.Caption = Int(Label2.Caption) + 1
End If
Next i
End Sub
Private Sub Form_Load()
capt (5)
End Sub
Private Sub Timer2_Timer()
For i = 0 To 4
Label1(i).Top = Label1(i).Top + 100
If (Label1(i).Top >= Form1.Height) Then
j = Int(Rnd(Form1.Width) * Form1.Width + 1)
Label1(i).Top = 0
Label1(i).Width = j
capt (i)
End If
Next i
End Sub
---------------------------------
高手来下哈...
Sub capt(ii As Integer) '自定义过程
S = "asdfghjklqwertyuiopzxcvbnm1234567890" '变量s值
If (ii = 5) Then '如果ii=5 则执行for循环
For i = 0 To 4
i2 = Int(Rnd(Len(S) - 1) * Len(S) + 1) '1到变量s字符长度区间随机选取一个数
ss = Mid(S, i2, 1) '从s里截取位置(随机数i2)的字符赋值给ss
Label1(i).Caption = ss 'ss值赋值给 标签
Next i
Else
i3 = Int(Rnd(Len(S) - 1) * Len(S) + 1) '同上
ss = Mid(S, i3, 1)
Label1(ii).Caption = ss
End If
End Sub
Private Sub Command1_Click()
If Command1.Caption = "停止" Then
Command1.Caption = "继续"
Timer2.Enabled = False
Else
Command1.Caption = "停止"
Timer2.Enabled = True
End If
End Sub
Private Sub Command1_KeyDown(KeyCode As Integer, Shift As Integer)
For i = 0 To 4
If LCase(Trim(Label1(i).Caption)) = LCase(Chr(KeyCode)) Then 'lcase转换大小写
j = Int(Rnd(Form1.Width) * Form1.Width + 1)
Label1(i).Top = 0
Label1(i).Width = j
capt (i) '调用过程capt
Label2.Caption = Int(Label2.Caption) + 1
End If
Next i
End Sub
Private Sub Form_KeyDown(KeyCode As Integer, Shift As Integer)
For i = 0 To 4
If LCase(Trim(Label1(i).Caption)) = LCase(Chr(KeyCode)) Then
j = Int(Rnd(Form1.Width) * Form1.Width + 1)
Label1(i).Top = 0
Label1(i).Width = j
capt (i)
Label2.Caption = Int(Label2.Caption) + 1
End If
Next i
End Sub
Private Sub Form_Load()
capt (5)
End Sub
Private Sub Timer2_Timer()
For i = 0 To 4
Label1(i).Top = Label1(i).Top + 100 '标签上边距+100
If (Label1(i).Top >= Form1.Height) Then '如果超过窗体高度
j = Int(Rnd(Form1.Width) * Form1.Width + 1)
Label1(i).Top = 0
Label1(i).Width = j
capt (i)
End If
Next i
End Sub
其他都很简单.应该不会不懂吧.
S = "asdfghjklqwertyuiopzxcvbnm1234567890" '变量s值
If (ii = 5) Then '如果ii=5 则执行for循环
For i = 0 To 4
i2 = Int(Rnd(Len(S) - 1) * Len(S) + 1) '1到变量s字符长度区间随机选取一个数
ss = Mid(S, i2, 1) '从s里截取位置(随机数i2)的字符赋值给ss
Label1(i).Caption = ss 'ss值赋值给 标签
Next i
Else
i3 = Int(Rnd(Len(S) - 1) * Len(S) + 1) '同上
ss = Mid(S, i3, 1)
Label1(ii).Caption = ss
End If
End Sub
Private Sub Command1_Click()
If Command1.Caption = "停止" Then
Command1.Caption = "继续"
Timer2.Enabled = False
Else
Command1.Caption = "停止"
Timer2.Enabled = True
End If
End Sub
Private Sub Command1_KeyDown(KeyCode As Integer, Shift As Integer)
For i = 0 To 4
If LCase(Trim(Label1(i).Caption)) = LCase(Chr(KeyCode)) Then 'lcase转换大小写
j = Int(Rnd(Form1.Width) * Form1.Width + 1)
Label1(i).Top = 0
Label1(i).Width = j
capt (i) '调用过程capt
Label2.Caption = Int(Label2.Caption) + 1
End If
Next i
End Sub
Private Sub Form_KeyDown(KeyCode As Integer, Shift As Integer)
For i = 0 To 4
If LCase(Trim(Label1(i).Caption)) = LCase(Chr(KeyCode)) Then
j = Int(Rnd(Form1.Width) * Form1.Width + 1)
Label1(i).Top = 0
Label1(i).Width = j
capt (i)
Label2.Caption = Int(Label2.Caption) + 1
End If
Next i
End Sub
Private Sub Form_Load()
capt (5)
End Sub
Private Sub Timer2_Timer()
For i = 0 To 4
Label1(i).Top = Label1(i).Top + 100 '标签上边距+100
If (Label1(i).Top >= Form1.Height) Then '如果超过窗体高度
j = Int(Rnd(Form1.Width) * Form1.Width + 1)
Label1(i).Top = 0
Label1(i).Width = j
capt (i)
End If
Next i
End Sub
其他都很简单.应该不会不懂吧.
英语翻译Sub capt(ii As Integer)S = "asdfghjklqwertyuiopzxcvbnm12
Private Sub Command1_Click() Dim i As Integer,s As Integer,n
英语翻译Private Sub 主体_Print(Cancel As Integer,PrintCount As Int
麻烦解释这个程序Private Sub pl(x As Integer,ByVal y As Integer)x = 4
英语翻译如题,程序是这样的:Public Sub RecordEdit()Dim intCount As Integer
英语翻译Private Sub Form_Click()Dim a(1 To 10) As Integer,i%,max
b求π为啥是错的Private Sub Command1_Click()Dim s As Integer,n As Do
Private Sub Command1_Click() Dim i,j As Integer For i = 3 To
Private Sub Form_Click() Dim a As Integer,b As Integer,k As
下列代码的意思Sub Saveas()Dim Mrow%,I%,n%Dim Y As Integer'Arr = [a2
dim i as integer dim sum as integer sum=0 for i=0 to 5 sum=s
帮忙VB试题我怎么想都算不对Private Sub Command1_Click()Dim a As Integer,b