Private Sub Form_Load()
Dim Handbrake As Boolean
Handbrake = False
Dim Start As Boolean
Start = False
End Sub
Private Sub Command7_Click()
If Start = False Then
Start = True
ElseIf Start = True Then
Start = False
End If
If Handbrake = False And Start = True Then
Command1.Enabled = True
Command2.Enabled = True
Command3.Enabled = True
Command4.Enabled = True
Command5.Enabled = True
Command6.Enabled = True
Command8.Enabled = True
Command9.Enabled = True
Command10.Enabled = True
ElseIf Handbrake = True And Start = True Then
Command1.Enabled = False
Command2.Enabled = False
Command3.Enabled = False
Command4.Enabled = False
Command5.Enabled = True
Command6.Enabled = True
Command8.Enabled = True
Command9.Enabled = True
Command10.Enabled = True
ElseIf Start = False Then
Command1.Enabled = False
Command2.Enabled = False
Command3.Enabled = False
Command4.Enabled = False
Command5.Enabled = False
Command6.Enabled = False
Command8.Enabled = False
Command9.Enabled = False
Command10.Enabled = False
End If
End Sub
Private Sub Command11_Click()
If Start = True Then
Select Case Handbrake
Case Is = True
Command1.Enabled = False
Command2.Enabled = False
Command3.Enabled = False
Command4.Enabled = False
Case Is = False
Command1.Enabled = True
Command2.Enabled = True
Command3.Enabled = True
Command4.Enabled = True
End Select
End If
End Sub
結果Command7不能執行Start = False 那部分
而Command11不能執行
如何解決?