An entry point cannot be marked with the 'async' modifier

前端 未结 5 1811
甜味超标
甜味超标 2020-12-05 13:08

I copied below code from this link.But when I am compiling this code I am getting an entry point cannot be marked with the \'async\' modifier. How can I m

5条回答
  •  暖寄归人
    2020-12-05 13:22

    Wrap your async code in MainAsync() - which is an async function
    then call MainAsync().GetAwaiter().GetResult();

提交回复
热议问题