大侠现在按X是失效。。。可是进入后窗体没有关掉???还是不行? 我用的是这个代码: Private Sub Workbook_Open() Application.Visible = False 登入.Show End Sub ********************************* 窗体代码: Private Sub CommandButton1_Click() If TextBox1.Value = "333" And TextBox2.Value = "123" Then Unload Me Else MsgBox " 密码错误" ThisWorkbook.Close False End If Application.Visible = True End Sub --------- Private Sub CommandButton2_Click() ThisWorkbook.Close False End Sub ------------ Private Sub TextBox1_Change() End Sub ----------- Private Sub UserForm_QueryClose(Cancel As Integer, CloseMode As Integer) If Cancel = False Then Cancel = True End Sub 如何关掉窗体??代码??
[此贴子已经被作者于2008-3-28 23:30:07编辑过] |