用sendmessage为何不行!!!!!!
Dim str1 As String
str1 = InputBox("input the proname want to close:")
hwnd1 = FindWindow(vbNullString, str1)
If hwnd1 = 0 Then
MsgBox 0
Else
MsgBox hwnd1
a = SendMessage(hwnd1, WM_CLOSE, 1, 1)
End If
利用上段代码可以检测到要关闭的程序是否打开,但不能关闭,请教高手!!!