|
-
May 18th, 2001, 03:19 AM
#1
Thread Starter
Addicted Member
Check App
How do I check to see if an application is runnning, if it is I just want to wait until it has completed.
Thanks
-
May 18th, 2001, 06:19 AM
#2
To see if an application is running by knowing it's exe, take a look at this thread.
Or you can use the FindWindow API function.
Code:
Private Declare Function FindWindow Lib "user32" Alias _
"FindWindowA" (ByVal lpClassName As String, _
ByVal lpWindowName As String) As Long
Private Sub Command1_Click()
Dim hWin As Long
hWin = FindWindow("SciCalc", "Calculator")
'FindWindow(class,caption)
If hWin <> 0 Then
Msgbox "Window found!", 64, hWin
Else
Msgbox "Window not found, 64, hWin
End If
End Sub
-
May 18th, 2001, 06:31 AM
#3
Thread Starter
Addicted Member
Thanks, I presume this is ok on NT?
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|