📄 listkillform.frm
字号:
VERSION 5.00
Object = "{82EDD048-7E49-11D2-8D41-444553540000}#1.0#0"; "LISTKILLPROCESS.OCX"
Begin VB.Form ListKillForm
Caption = "Windows 进程管理"
ClientHeight = 3660
ClientLeft = 60
ClientTop = 375
ClientWidth = 9420
BeginProperty Font
Name = "MS Sans Serif"
Size = 8.25
Charset = 0
Weight = 700
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
LinkTopic = "Form1"
ScaleHeight = 3660
ScaleWidth = 9420
StartUpPosition = 3 '窗口缺省
Begin VB.CommandButton Command2
Caption = "退出系统"
BeginProperty Font
Name = "MS Serif"
Size = 9.75
Charset = 0
Weight = 700
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 495
Left = 7080
TabIndex = 3
Top = 2040
Width = 1815
End
Begin VB.CommandButton Command1
Caption = "清屏"
BeginProperty Font
Name = "MS Serif"
Size = 9.75
Charset = 0
Weight = 700
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 495
Left = 7080
TabIndex = 2
Top = 1200
Width = 1815
End
Begin ListAndKillProcess.ListKillProcess ListKillProcess1
Left = 1680
Top = 5280
_ExtentX = 873
_ExtentY = 873
End
Begin VB.CommandButton RefreshCommand
Caption = "刷新"
BeginProperty Font
Name = "MS Serif"
Size = 9.75
Charset = 0
Weight = 700
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 495
Left = 7080
TabIndex = 1
Top = 480
Width = 1815
End
Begin VB.ListBox ProcessList
BackColor = &H00000000&
BeginProperty Font
Name = "Times New Roman"
Size = 9
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
ForeColor = &H00E0E0E0&
Height = 2355
ItemData = "ListKillForm.frx":0000
Left = 120
List = "ListKillForm.frx":0002
Style = 1 'Checkbox
TabIndex = 0
Top = 480
Width = 6495
End
Begin VB.Line Line4
BorderColor = &H00E0E0E0&
X1 = 0
X2 = 6720
Y1 = 3000
Y2 = 3000
End
Begin VB.Line Line2
BorderColor = &H00E0E0E0&
X1 = 0
X2 = 6720
Y1 = 4200
Y2 = 4200
End
End
Attribute VB_Name = "ListKillForm"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Private Sub Command1_Click()
ProcessList.Clear
End Sub
Private Sub Command2_Click()
End
End Sub
Private Sub Form_Load()
ListKillProcess1.List_Processes = True
ProcessList.Clear
For i = 1 To ListKillProcess1.Number_Of_Processes
ListKillProcess1.Get_Process_Info = i
ProcessList.AddItem Str(i) + " " + ListKillProcess1.Process_Name
Next i
End Sub
Private Sub ProcessList_ItemCheck(Item As Integer)
ListKillProcess1.Get_Process_Info = Item + 1
Response = MsgBox(ListKillProcess1.Process_Name, vbOKCancel, "你确定结束进程吗?")
If Response = vbOK Then
ListKillProcess1.ID_To_Kill = ListKillProcess1.Process_ID
ListKillProcess1.Kill_Process = True
ListKillProcess1.List_Processes = True
ProcessList.Clear
For i = 1 To ListKillProcess1.Number_Of_Processes
ListKillProcess1.Get_Process_Info = i
ProcessList.AddItem Str(i) + " " + ListKillProcess1.Process_Name
Next i
Else
End If
End Sub
Private Sub RefreshCommand_Click()
ListKillProcess1.List_Processes = True
ProcessList.Clear
For i = 1 To ListKillProcess1.Number_Of_Processes
ListKillProcess1.Get_Process_Info = i
ProcessList.AddItem Str(i) + " " + ListKillProcess1.Process_Name
Next i
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -