|
-
Aug 29th, 2000, 04:23 PM
#1
Thread Starter
New Member
I use following code to open .HTML file with IE. I have to wait in loop while ie window or peocess behind it finishes.
The usuall microsoft example for waiting for shell program to finish, here doesn't work. I need to get some information, at least if Ie window is open, but Iswindow API doesn't work.
Public Declare Function ShellExecute Lib "shell32.dll" Alias _
"ShellExecuteA" (ByVal hwnd As Long, ByVal lpOperation As String, _
ByVal lpFile As String, ByVal lpParameters As String, ByVal _
lpDirectory As String, ByVal nShowCmd As Long) As Long
sub main
res = ShellExecute(0&, vbNullString, "c:\windows\desktop\proba.htm", vbNullString, vbNullString, vbNormalNoFocus)
If res <= 32 Then
MsgBox ("Unable to send information to internet!" & Chr(10) & "Next try will be when you login."), vbOKOnly
Exit Sub
End If
end sub
Please help, Thanks
-
Aug 29th, 2000, 06:13 PM
#2
Member
If it is any help, the shell command built into vb returns the task id, i dont know if this will be much good to you thoug, i suppose you could enumerate the tasks that are running on the system and check to see if the task you ran is there, but i am afraid i do not know how to enumerate the tasks on a system.
Sorry, just a stepping stone in a long path.
Grant French
-----------------------------------------------
E-Mail: [email protected]
ICQ: 33122184
-
Aug 29th, 2000, 09:59 PM
#3
Use a DoEvents which will wait until the program is loaded and complete the rest of the code.
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
|