简体   繁体   English

发生了错误。 : 在应用程序配置文件中找不到名为“EmployeeDBEntities”的连接字符串

[英]An error has occurred. : No connection string named "EmployeeDBEntities' could be found in the application config file

I am facing an error message when I try to run my ASP.Net web API.当我尝试运行我的 ASP.Net web API 时,我遇到了一条错误消息。

I have two projects in a solution.我在一个解决方案中有两个项目。
1- Class library for Entity Class Model. 1- Class 实体库 Class Model。
2- Web API Controllers. 2- Web API 控制器。

在此处输入图像描述

Error message when I try to run this application.当我尝试运行此应用程序时出现错误消息。

在此处输入图像描述

I could see in the Solution explorer, the app.config file is not in the startup project.我可以在解决方案资源管理器中看到,app.config 文件不在启动项目中。 So you could copy the app.config file to the EnoloyeeService project.因此,您可以将 app.config 文件复制到 EnoloyeeService 项目。 It should work then.它应该工作。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 在应用程序配置文件中找不到已命名的连接字符串 - No connection string named could be found in the application config file 在应用程序配置文件中找不到名为“CarAccountingEntities”的连接字符串 - No connection string named 'CarAccountingEntities' could be found in the application config file 在应用程序配置文件中找不到名为“ CREntities”的连接字符串 - No connection string named 'CREntities' could be found in the application config file 在应用程序配置文件中找不到名为“thenameofmyconnection”的连接字符串 - No connection string named “thenameofmyconnection” could be found in the application config file 在应用程序配置文件中找不到名为“MyEntities”的连接字符串 - No connection string named 'MyEntities' could be found in the application config file '在应用程序配置文件中找不到名为'MyEntities'的连接字符串。' - 'No connection string named 'MyEntities' could be found in the application config file.' 在应用程序配置文件中找不到名为“ KgSoftProContext”的连接字符串 - No connection string named 'KgSoftProContext' could be found in the application config file InvalidOperationException:在应用程序配置文件中找不到名为“PayMyRentEntities”的连接字符串 - InvalidOperationException: No connection string named 'PayMyRentEntities' could be found in the application config file 'EmployeeDBEntities' 可以在 C# Class 库项目的应用程序配置文件中找到 - 'EmployeeDBEntities' could be found in the application config file in C# Class Library project 如何在 WinForms 中处理“在应用程序配置文件中找不到名为‘RestaurentEntities’的连接字符串” - How to handle "No connection string named 'RestaurentEntities' could be found in the application config file" in WinForms
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM