C#

A 26-post collection

TaskCompletionSource - Bridging the Gap Between Old and New

In the latest versions of the .NET Framework, asynchronous work is represented by the Task class. A task is similar to a future or promise in other languages. You can »

Top 6 Industry Shifts During My IT Career

In the fall of 1999, I dropped my plans to attend grad school to embark on a career in IT. The industry has changed considerably since then mostly for the »

A Short and Easy Introduction to .NET's Task Class

Task.Run You can use Task.Run to schedule a delegate to run on the thread pool. The method returns a new task, and if the work is complete, the »

Specflow Tags Done Right

In a previous post, I covered scoped bindings in Specflow and ended with an example of how not to use tags. In this post, I'll cover the "right way" and »

An Introduction to Scoped Bindings in Specflow

One aspect of Specflow is the ability to scope bindings by feature title, scenario title, or tag. Normally bindings are global to the project, but a binding's scope can be »

Refactoring to Composable Specflow Steps

I've seen some pretty bad Specflow code. Code that seems to violate every good practice out there. Poor reuse. Copy and paste everywhere. Test code is the hotel room of »

Tidying Up Code with C#'s Using Alias Directives

The C# language's using alias directives or namespace and type aliases provide a way to disambiguate between namespaces or types with the same name. For example, both the System.Net »

Posted under .NET, C#

This Week in Programming Gotchas

We all have those days where we spend hours trying to solve a seemingly simple problem only to smack ourselves in the head when we finally figure it out. Missing »

String.Empty Versus ""

If you've been in the .NET world for any length of time, you'll eventually come across someone who claims String.Empty performs better than "". I was always skeptical of this »

Async/Await and Recursion

While using the new async/await keywords in C# 5.0 for the first time, I noticed an interesting aspect to how recursive methods behave when using await. For one »