M
Mike
Hello everyone:
I am looking for some VB.NET code samples that make use of waitable
timers that put the thread of the application to Sleep for the
specificied period of time. I am told that the benefit of using a
Waitable timer to the Threading.thread.Sleep function is that the
application will still be responsive to events, whereas
Threading.thread.Sleep will just freeze the application for the set
interval.
I have some VB6 code and a waitable timer class that I could not make
use of it in VB.NET.
Example: 'This is an example for idling your application
' Private mobjWaitTimer As WaitTimer
' Private Sub RunProcess()
' Set mobjWaitTimer = New WaitTimer
' Do
' If mbWorkToDo Then
' Call ProcessWork()
' Else
' mobjWaitTimer.Wait(5000) 'Wait for 5 seconds
' End If
' Loop Until Not mbStop
' Set mobjWaitTimer = nothing
' End Sub
I thank everyone that tried to offer me help.
I am looking for some VB.NET code samples that make use of waitable
timers that put the thread of the application to Sleep for the
specificied period of time. I am told that the benefit of using a
Waitable timer to the Threading.thread.Sleep function is that the
application will still be responsive to events, whereas
Threading.thread.Sleep will just freeze the application for the set
interval.
I have some VB6 code and a waitable timer class that I could not make
use of it in VB.NET.
Example: 'This is an example for idling your application
' Private mobjWaitTimer As WaitTimer
' Private Sub RunProcess()
' Set mobjWaitTimer = New WaitTimer
' Do
' If mbWorkToDo Then
' Call ProcessWork()
' Else
' mobjWaitTimer.Wait(5000) 'Wait for 5 seconds
' End If
' Loop Until Not mbStop
' Set mobjWaitTimer = nothing
' End Sub
I thank everyone that tried to offer me help.