async / await / task
>Visual Studio (2019 or later):OK, I have only VS2017.For private use,Community version VS 2019 is enough. It's TOTALLY FREE.Reproduce your quesions with ScreenToGif is your choice. For IIS: IIS...
View Articleasync / await / task
The key word "await" has NOTHING TO DO directly with "ManualResetEvent" and "AutoResetEvent". It's ONLY a symbol to tell the compiler that the Task instance should be working in the async mode. Now a...
View Articleasync / await / task
OK, but what is the best way? - Task.WaitAll -> is clear I understand. - ManualResetEvent - await - AutoResetEvent Can you show that for the variants? name the advantages...
View Articleasync / await / task
OK, but what is the best way? - Task.WaitAll -> is clear I understand. - ManualResetEvent - await - AutoResetEvent Can you show that for the variants? name the advantages...
View Articleasync / await / task
public Task Step1() { return Task.Run (……); } public Task Step2() { return Task.Run (……); } // Some other class or method... while (!UserPressStop) { public void Controller() { Step1(); Step2();...
View Articleasync / await / task
>For 2nd question, maybe Task.WaitAll is OKCan you create a short sample to see it please?Thanks.Greetings Markus
View Articleasync / await / task
Markus Freitag:For 2nd question, maybeTask.WaitAll is OK, but please notice that you should make sure the two tasks WON'T effect each other, they WON'T have common-shared data...ect, because they are...
View Articleasync / await / task
Markus Freitag:About the sample, please follow the rules here: Building the sample To download and run the sample, follow these steps:Download and unzip the sample.In Visual Studio (2019 or later):On...
View Articleasync / await / task
Hi ThankfulHeart,Thanks for the response.The project is empty. Do you have the full project?// --------------https://docs.microsoft.com/de-de/dotnet/csharp/programming-guide/concepts/async/ Do you have...
View Articleasync / await / task
Hi Markus Freitag:1) This sample given by you isn't complete, and for full runnable sample, please download this WPF version instead...
View Articleasync / await / task
Hello Karen, Thank you very much, it works well. Why you used. await Task.Run(() => operations.Example1Async(personArgs1, progress));Here you use.Task<Person> taskOne = await...
View Articleasync / await / task
Hi Karen, Thanks.Reference missing.Microsoft.office.coreMicrosoft.office.interop.excelI haven't SQL server.Is there a way to run your sample easy?Greetings MarkusHere I placed everything you need into...
View Articleasync / await / task
Hi Markus,When I run your code with Visual Studio 2019 and .net Framework 4.7.2, it works well.Maybe you can try to update your Visual Studio.Best Regards,TimonMSDN Community Support Please remember to...
View Articleasync / await / task
Hi Karen, Thanks.Reference missing.Microsoft.office.coreMicrosoft.office.interop.excelI haven't SQL server.Is there a way to run your sample easy?Greetings Markus
View Articleasync / await / task
Hi Timon,I use Visual Studio 2017 Prof. Version 15.9.6Is too old?What is the best way for that version?Greetings Markus
View Articleasync / await / task
Hi Markus,Thank you for posting here.Could you please tell us what version of C# and Visual Studio you are using? Because according to the error message of your second link, it seems that this error is...
View Articleasync / await / task
If the intent is to have task and wait on them check out a simple example which has two task and uses Task.WaitAll I have here, otherwise best to start with a smaller code sample.Please remember to...
View Articleasync / await / task
Hello, Is good for understanding. Does anyone have the complete example?https://github.com/dotnet/docs/blob/master/docs/csharp/programming-guide/concepts/async/index.mdIs not workingI use a class for...
View Article