I am trying to use the 'async' and 'await' keywords in VS C# 2010 Express but i can't seem to use this keyword. However, when I use this keyword in VS C# 2012 Professional, it can be used. Is there a special thing that I must download to use it?
In computer programming, the async/await pattern is a syntactic feature of many programming languages that allows an asynchronous, non-blocking function to be structured in a way similar to an ordinary synchronous function.
An async function is a function declared with the async keyword, and the await keyword is permitted within it. The async and await keywords enable asynchronous, promise-based behavior to be written in a cleaner style, avoiding the need to explicitly configure promise chains.
With the new C++11 standard, there is std::async . Pretty much anything the machine is capable of can be done in C, you just have to do it yourself.
Synchronous means that the block is executed at the same time (though, yes, the components are executed sequentially). Asynchronous means that the block is not all executed at the same time.
The async
/await
feature was introduced in C# 5, which isn't supported by VS 2010. While the Community Technology Previews extended VS2010, I would strongly advise you to use the release version of VS 2012 instead of pre-releases. The CTPs had a few bugs, and in general it's not a good idea to use pre-release features when the RTM version is available.
Note that this isn't an Express vs Professional issue - if you upgrade from VS C# 2010 Express to VS C# 2012 Express it'll work fine.
Its a new feature in 2012 and you cant use it in vs 2010.
http://msdn.microsoft.com/en-us/library/hh156513%28v=vs.110%29.aspx
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With