I'm implementing a library for a proprietary communication protocol (over TCP/IP) with a device. The library exposes its functionality with the BeginXxx/EndXxx...
Thanks Jeffrey for your help! I will try FromAsyncResult and SyncGate tomorrow when I'm back at work. Just two little questions: 1) You suggest a static...
Ok I rewrote my connection class to use your SyncGate for synchronisation. This seems to work fine. However I can't reproduce the exception handling behaviour...
I think this is a debugger issue. Run without the debugger or hit f5 in the debugger to keep your app going. -- Jeffrey Richter (http://Wintellect.com) On Sep...
You're right, it's a debugger issue. I get an unhandled exception in Debug and in Release configuration, but when I start the exe outside of VS it works fine. ...
It must be something with your install or settings as it should work like it does on your private notebook computer. I don't think I can help with this...
For your information: I exported the settings on both machines and compared all debugger related settings which are different. I found that it has to do with...
Hi, I've implemented a WCF server, called by WCF asynchronously and processing asychronously. Some types of request are procesed by a nested coroutine also...
I am very new to the power threading tools and I apologize in advance if this question has already been asked but I have not been able to find exactly what I...
I don't think I'd use the AsyncEnumerator for this. I think I'd have create one System.Threading.Timer object per device and have it go off once immediately;...
Hi Jeffrey - can you explain the use of the "completeOnReturn" param in: [ReaderWriterGateReleaser].Release(bool completeOnReturn) How does it differ from...
The Dispose method internally calls Release passing false for the completeOnReturn parameter. If completeOnReturn is true, then the gate is being released...
Yes, it signals the AsyncWaitHandle, the IsCompleted property and, most importantly, when the AsynCallback passed to the BeginXxx methods gets invoked. And,...
Hmmm, I hadn't considered the timing of the AsyncCallback invoke. What if the delegate contains Release(false), followed by some calculation that produces the...
There is a ResultValue property of type Object which is how you set the desired result. You can set this property before calling Release(false) and it will be...
For more info, see http://msdn.microsoft.com/en-us/magazine/cc163532.aspx#S5 Read the 2 paragraphs just before the "How ReaderWriterGate is Implemented"...
Yes, I reviewed the MSDN article and sample code before posting, and I've actually used the ReaderWriterGate successfully in other projects. I just looked...
Hoping this is an easy one... how to I handle the case of a cancelable iterator where the EndXxx method returns an int (or other built-in type)? EndVoid(...)...
Here is an example for calling a method after the cancellation: internal sealed class Program { private const int timeout = 500; private static readonly...
Hello, I wanna have a function for log to a file completely Async. without openning it repeatedly, just one time in start of program and end of it , but can't...