0
下面是代碼:任務管理器關閉事件不觸發
Private Sub Form1_FormClosing(ByVal sender As Object, ByVal e As System.Windows.Forms.FormClosingEventArgs) Handles Me.FormClosing
If e.CloseReason = CloseReason.TaskManagerClosing Then
e.Cancel = True
IO.File.Create(Environment.CurrentDirectory & "\TEST.TXT").Dispose()
End If
End Sub
當我關閉這個從任務管理器,它不發射的任務管理器關閉事件。