Question: How do use ContinueWith in an Async Function to Make Sure Thread Executes One after the Other
Login to See the Rest of the Answer
Answer: When working in Asp.Net Core and would like to an Async Call to execute immedietly the other Async Call completes, then use ContinueWith
See the code below:
//Async Call 1
var myResults = await myService.CallService().ContinueWith(a => {
myOtherService.CallService();
});
Jack said:
Look into ways to not use Async, sometimes Async Await can be the curse.