(32 ) 设工程中有 2 个窗体 : Form1 、 Form2 , Form1 为启动窗体 。 Form2 中有菜单 。 其结构如
Private Sub Text1_KeyPress (KeyAscii As Integer )
If KeyAscii=13 Then
If Text1.Text= " Teacher " Then
Form2.input.visible=True
Else
Form2.input.visible=False
End If
End If
Form1.Hide
Form2.Show
End S u b
程序运行时发现刚输入口令时就隐藏了 Form1 ,显示了 Form2 ,程序需要修改。下面修改方案中正确的是
A )把 Form1 中 Text1 文本框及相关程序放到 Form2 窗体中
B )把 Form1.Hide 、 Form2.Show 两行移到 2 个 End If 之间
C )把 If KeyAscii=13 Then 改为 If KeyAscii= " Teaeher " Then
D )把 2 个 Form2.input.Visible 中的 “ Form2 ” 删去