DoEvents different in Win98/WinNT ? 
Author Message
 DoEvents different in Win98/WinNT ?

I have a application in VB6 which calls functions in a multithreaded DLL
used for comms. To transfer large amounts of data (ie takes 5 seconds) I
have thread functions in the DLL to do the job so that the VB application
doesn't suspend execution waiting for a function to return.
I want to display a progress bar of how much data the thread has
successfully transferred on the VB app, by simply polling a DLL function to
return a value using a normal timer. While this thread runs, I need to
suspend the operation of the calling VB function until the thread has
finished, and this is the problem.
Under WinNT, Win2K a DoEvents loop works fine, the thread runs, everything
works. Under Win98 the thread runs at about 1/10th speed. Is this down to
the multithreading model being different on NT and 95/98 platforms ? If so
is there much I can do about it ? It seems DoEvents gives more processor
time to background tasks in NT, and 98 gives higher priorities to the active
Other option I tried was to pass back the thread handle from the DLL, and
call WaitForSingleObject in VB. This halts the VB function until the thread
has finished, but it also halts the rest of the application - which I don't
want !
Is there any way of getting around this problem ?

Best regards,

Tom Marshall.

Sat, 11 Sep 2004 17:11:50 GMT  
 [ 1 post ] 

 Relevant Pages 

1. WinNT vs. Win98 differences opening binary files

2. Win98 to WinNt(sp4) PROBLEMS !!

3. Installing VB application on Win98 and WinNT?

4. VBA with WinNT Vs Win98

5. winnt restart win98

6. Deploying Controls from Win98 to WinNT

7. Screen Res: WinNT develop to Win98 deploy

8. WinNT vs. Win98 differences opening binary files

9. Win98 to WinNt(sp4)

10. Problems with WinSock on a small WinNt/Win98 local network

11. Different program behaviour, VB6 and WinNT

12. GetPrivateProfileString different in WinNT?


Powered by phpBB® Forum Software