Tag Archives: async

Cannot find all types required by the ‘async’ modifier

If you use the async and await keyword in .NET 4.0 with Visual Studio 2012, you may get following error.

Cannot find all types required by the ‘async’ modifier. Are you targeting the wrong framework version, or missing a reference to an assembly?

The problem is that you have not installed the API that is necessary to use the ‘async’ and ‘await’ keyword in the 5.0 version of C#. Furthermore you get this exception only if you use those two keywords in .NET 4.0 applications. You will not see this exception neither in .NET 4.0 nor in WinRT apps.

The solution to this problem is to reference following nuGet package into all projects in which you want to use the ‘async’ and ‘await’ keyword:


Leave a comment

Posted by on September 19, 2012 in C-Sharp


Tags: ,