简体   繁体   中英

Can't run a C# web API in Visual Studio 2022

I am trying to run a web API written in C#,in Visual Studio code 2022 but I keep getting this error

An unhandled exception of type 'System.IO.FileNotFoundException' occurred in Unknown Module. Could not load file or assembly 'System.Runtime, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot find the file specified.

I was having the exact same error, it turned out Visual Studio just needed an update.

Updated it and restarted the app and it went away.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM