C# 2012, Part 3 of 4: Asynchronous Programming
Interactive

C# 2012, Part 3 of 4: Asynchronous Programming

LearnNow Online
Updated Aug 23, 2018

Course description

In this course you’ll learn about what async is and how it’s different from traditional synchronous programming. You’ll also learn the benefits of async. Before going into the new async language features, you’ll see how the previous async models worked and have a better understanding for what the problems were. This will form a basis of appreciation for how easy the new C# async model is and what the benefits are for you. Next, you’ll see the fundamental mechanics of how an async method is defined. You’ll learn how to use the new async and await contextual keywords to perform async operations. You’ll learn about different types of return values and when you should use each. The course will also cover common techniques of managing async tasks either sequentially or in parallel. You’ll learn how to catch exceptions from async code and what type of code to write to ensure that you can catch exceptions. You’ll learn how to cancel one or more async operations in predictable ways. Further, you’ll see how progress reporting occurs and the ease in which you can integrate it with async methods.

Each LearnNowOnline training course is made up of Modules (typically an hour in length). Within each module there are Topics (typically 15-30 minutes each) and Subtopics (typically 2-5 minutes each). There is a Post Exam for each Module that must be passed with a score of 70% or higher to successfully and fully complete the course.


Prerequisites

This course assumes that students understand the C# 3.0 syntax and have a basic understanding of the .NET Framework. No specific experience with Visual Studio 2012 is required.


Meet the expert

Joe Mayo

Joe Mayo is an author, independent consultant, and instructor specializing in Microsoft .NET and Windows 8 technology. He has several years of software development experience and has worked with .NET since July 2000. Joe has written books and contributes to magazines such as CODE Magazine. He has been an active contributor to the .NET community for years, operating the C# Station Web site, authoring the LINQ to Twitter open source project, and speaking regularly at user groups and code camps. For his community contributions, Microsoft has honored Joe with several Most Valuable Professional (MVP) Awards through the years.

Video Runtime

53 Minutes

Time to complete

206 Minutes

Course Outline

Async Programming

Async Programming (13:24)

  • Introduction (00:40)
  • Where Async Fits In (03:10)
  • Demo: Synchronous Problems (01:00)
  • Previous Async Technologies (00:57)
  • Demo: APM Async Model (05:05)
  • Demo: Event-Based Async Model (02:14)
  • Summary (00:15)

Writing Async Code (27:57)

  • Introduction (01:34)
  • Anatomy of an Async Method (01:23)
  • Demo: Async Method (14:11)
  • Async Return Values (01:55)
  • Demo: Async Return Values (02:12)
  • About Async Threads (00:47)
  • Awaiting in Sequence (00:37)
  • Demo: Awaiting in Sequence (01:17)
  • Awaiting in Parallel (01:04)
  • Demo: Awaiting in Parallel (02:37)
  • Summary (00:15)

Except, Cancel, and Progress (12:24)

  • Introduction (00:37)
  • Handling Exceptions (00:20)
  • Demo: Handling Exceptions (03:16)
  • Cancellation (00:48)
  • Demo: Cancellation (03:17)
  • Progress Reporting (00:57)
  • Demo: Progress Reporting (02:21)
  • Summary (00:45)