如何解决ASP.NET中系统无法找到文件的问题

今天就跟大家聊聊有关如何解决ASP.NET中系统无法找到文件的问题,可能很多人都不太了解,为了让大家更加了解,小编给大家总结了以下内容,希望大家根据这篇文章可以有所收获。

ASP.NET The system cannot find the file specified解决办法

Server Error in '/' Application.


The system cannot find the file specified

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.ComponentModel.Win32Exception: The system cannot find the file specified


如何解决ASP.NET中系统无法找到文件的问题

 Insus.NET开发时,数据库是使用企业版,因此连接字符串就是写成默认的实现,而现在部署的数据库是\SQLEXPRESS。所以我们修改一下连接字符串:

如何解决ASP.NET中系统无法找到文件的问题

直接把127.0.0.1改为:“SVR1\SQLEXPRESS

 如何解决ASP.NET中系统无法找到文件的问题

 其实你还可以使用下面的Server字符串:

改为,使用英文字符点“.\SQLEXPRESS”:

如何解决ASP.NET中系统无法找到文件的问题

 或者使用“localhost\SQLEXPRESS”:
如何解决ASP.NET中系统无法找到文件的问题

 或者使用IP地址:
如何解决ASP.NET中系统无法找到文件的问题

看完上述内容,你们对如何解决ASP.NET中系统无法找到文件的问题有进一步的了解吗?如果还想了解更多知识或者相关内容,请关注行业资讯频道,感谢大家的支持。