|
-
Sep 28th, 2001, 12:19 PM
#1
Thread Starter
New Member
shellexecute stalls/halts
The following seems to work except for one program called Falconview. I wrote a program to launch, size, and place windows on the screen. The only way I can get the program to launch is through association, the reason for shellexecute. Then in order to get the file handle I'm getting off of FindWindow(null, window_text). I have the findwindow text into a do while loop so it looks for it for 30 seconds since it takes time for the program to launch. If I step throught the code in a debug window this works fine but if I run it from VB6 or a compiled exe it seems to freeze the program during mid launch, then after the do loop is finished it completes the launching of the app.
the basic code is...
STATUS=ShellExecute((hw&, APP_Assoc, vbnull, vbnull, 1)
.
.
do while IS_RUNNING = vbFalse
hw&=FindWindow(vbnullstring, APP_Text)
if hw& > 0 then IS_RUNNING = vbTrue
loop
any suggestions on how to check to see if the app launched then get it's handle. I can't get it's application class.
chris
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
|