Tags: Tasks

Fixing Patterns for Async MVVM Applications

Download the code here –AsyncCommands If you like this post you might also like an interesting post on Deadlocks while using tasks. This post is a follow up on Stephen Cleary’s excellent post on MSDN here which is a series of articles he wrote to explain how Tasks based patterns can be effectively adopted for GUI/MVVM applications. […]

Read More →

Deadlocks when using Tasks

What is wrong with this code? public static class NiksMessedUpCode { private static async Task DelayAsync() { await Task.Delay(1000); } public static void Test() { // Start the delay. var delayTask = DelayAsync(); // Wait for the delay to complete. delayTask.Wait(); } }   The code compiles without errors yet there is something really terrible […]

Read More →