女士小型汽车图片:vb,解释下面一段代码.

来源:百度文库 编辑:神马品牌网 时间:2024/05/01 00:51:26
第一段
Private Sub Timer1_Timer()
Static a% ?这个不知道
a = a + 1 这个知道
If P1.Top > P2.Top + P2.Height Then 这个知道
P1.Move P1.Left, P1.Top - 5 - a, P1.Width, P1.Height 这个不知道
Else
Timer1.Enabled = False 这个知道
End If
End Sub

第二段代码
我都不知道
Private Sub Form_Unload(Cancel As Integer)
Open "out4.txt" For Output As #1
Print #1, Op1.Value, Op2.Value, Text1.Text
Print #1, Ch1.Value, Ch2.Value, Text2.Text
Close #1
End Sub

我才学,希望你把这些解读出来什么意思,给我看.

Open "out4.txt" For Output As #1 打开文件out4.txt并用#1这个名称标识

Print #1, Op1.Value, Op2.Value, Text1.Text 分别显示到控件中
Print #1, Ch1.Value, Ch2.Value, Text2.Text
Close #1 关闭文件