|
-
Jun 16th, 2010, 07:27 AM
#1
Thread Starter
New Member
How to get more process information
We have a VB6 exe that executes .msi (installer files) using shell...
lPid = Shell(strInstall, vbNormalFocus)
If lPid <> 0 Then
'Get a handle to the shelled process.
lHnd = OpenProcess(SYNCHRONIZE, 0, lPid)
'If successful, wait for the application to end and close the handle.
If lHnd <> 0 Then
lRet = WaitForSingleObject(lHnd, INFINITE)
CloseHandle (lHnd)
End If
End If
So, because of the WaitForSingleObject, one install is executed after the other. As each install starts, I display the name of the install in a text box so that the users can see that things are processing. Some of these installs can take awhile to complete (they are silent), and I would like to give the users a little for information if possible.
I know that I can do a loop with "ret = WaitforSingleObject(lHnd, 10)", but what information can I gather about the process that I can display to the user (cpu time accumulated, or what), so that the user can see that things are processing and not hung? Give an example if you can. Thanks.
-
Jun 16th, 2010, 07:49 AM
#2
Re: How to get more process information
Hmm.. interesting question. Does the installer have a screen/window even though it's not visible? Maybe you can grab the value of a progress bar if it has one.
One other thing you could do is create a custom 'running' progress bar, those that just run from one end to the other, to show that the application is processing.
-
Jun 16th, 2010, 08:08 AM
#3
Thread Starter
New Member
Re: How to get more process information
I am already displaying the name of the installer that is running, in a text box, I am not sure what adding a drop down list box will do as for showing information as to whether or not the process is running or hanging.
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
|