Tutorial, Dotnet, Csharp, Programming, Coding.
Managing Parallel Tasks The Task class is fundamental to TPL. You can create and start tasks with it. Task myTask = Task.Run(() => { // your code here Console.WriteLine("Doing some work..."); }); myTask.Wait(); In this snippet, we create a task that prints a message and then waits for its