Tag Archives

Archive of posts published in the tag: Winforms

Exception propagation in WinForms

Let’s start with the following code: using System; using System.Windows.Forms; class Program1 { [STAThread] static void Main() { var form = new Form(); form.Load += (sender, e) => throw new Exception(); try { Application.Run(form); } catch(Exception e) { MessageBox.Show(“This doesn’t execute”); } finally…

Async Wandering Part 3 — Awaiting in synchronous WinForms code

This is the third part of the Async Wandering series. For your convenience you can find other parts in the table of contents in Part 1 – Why creating Form from WinForms in unit tests breaks async? async and await are great features…

Async Wandering Part 2 — Synchronous call on WinForms control and ObjectDisposedException

This is the second part of the Async Wandering series. For your convenience you can find other parts in the table of contents in Part 1 – Why creating Form from WinForms in unit tests breaks async? I once found the following code…

Async Wandering Part 1 — Why creating Form from WinForms in unit tests breaks async?

This is the first part of the Async Wandering series. For your convenience you can find other parts using the links below (or by guessing the address): Part 1 — Why creating Form from WinForms in unit tests breaks async? Part 2 —…