原文:Unable to resolve service for type`***` while attempting to activatre `***`

出現上圖那樣的情況 一般是沒有在Startup類中的ConfigureServices中注入接口和實現類 注入一個就ok ...

2021-05-14 13:43 0 1417 推薦指數:

查看詳情

Unable to resolve service for type的問題

今天寫了一個方法和接口,需要將接口通過依賴注入的方式注入到Controller里面,但是卻出現了InvalidOperationException: Unable to resolve service for type ...

Wed Apr 29 07:15:00 CST 2020 2 8080
 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM