Click to See Complete Forum and Search --> : WaitForASingleObject(handle , Timeout) Time out for waiting function in C#?


w2457ie
April 21st, 2004, 05:09 AM
Hello ,

I'm programming in C# in the SmartSolution for pocket PC environment .
I've defined a CAutoRestetEvent and noticed that there is only WaitOne() function
Which does not allow Time out .
I'm looking for something that will support waiting on a specific handle with timeout like - WaitOne(5000) .


Thanks in advance …

Marc G
April 21st, 2004, 11:48 AM
There is a WaitOne(int, bool) and WaitOne(TimeSpan, bool) (look them up in the MSDN)
Or read the sample with WaitOrTimerCallback in the MSDN.

w2457ie
April 21st, 2004, 11:50 AM
Not in compact frame work , they are not overloaded . only in regular .