//同步方法調用異步方法 public static string Test(string cName) { AutoResetEvent autoResetEvent = new AutoResetEvent(false); ThreadPool.QueueUserWorkItem(async (str) => { var custom = cusService.SelectOne(c => c.CUSTOM_NAME == cName).GetAwaiter().GetResult(); autoResetEvent.Set(); // 工作完成後設置信號 } var b = autoResetEvent.WaitOne(); // 等待信號 }