I\'m going to use lots of tasks running on my application. Each bunch of tasks is running for some reason. I would like to name these tasks so when I watch the Parallel Tasks wi
You can't really name a Task
, but you can name the method which is executed by a Task
, which is then shown in the Parallel Tasks windows. So, if naming the Task
s is important for you, don't use lambdas, use normal named methods.
Surprisingly, this works even with Parallel
, even though there the Task
isn't executing your method directly. I think this is because Parallel Tasks somehow knows about Task
s from Parallel
and handles them differently.