错误Apeare对我来说,我,使用ASP.NET MVC&实体框架 [英] Error Apeare For me , I,m using ASP.NET MVC & Entity Framework

查看:74
本文介绍了错误Apeare对我来说,我,使用ASP.NET MVC&实体框架的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

不支持关键字:'v11.0; attachdbfilename'。

描述:执行当前Web请求期间发生了未处理的异常。请查看堆栈跟踪以获取有关错误及其在代码中的起源的更多信息。



异常详细信息:System.ArgumentException:不支持关键字:'v11.0 ; attachdbfilename'。



来源错误:





第13行:{

第14行:EmployeeContext empContext = new EmployeeContext();

第15行:员工emp = empContext.Employees.Single(employee => employee.EmployeeID == id) ; //单(employee => employee.EmployeeID == id);

第16行:返回查看(emp);

第17行:}

Keyword not supported: 'v11.0; attachdbfilename'.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.ArgumentException: Keyword not supported: 'v11.0; attachdbfilename'.

Source Error:


Line 13: {
Line 14: EmployeeContext empContext = new EmployeeContext();
Line 15: Employee emp = empContext.Employees.Single(employee => employee.EmployeeID == id);//Single(employee => employee.EmployeeID == id);
Line 16: return View(emp);
Line 17: }

推荐答案

此错误必须是因为您的连接字符串。

您能否发布连接字符串。
This error must be because of your connection string.
Can you post you connection string.


这篇关于错误Apeare对我来说,我,使用ASP.NET MVC&实体框架的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆