登录失败。该登录名来自不受信任的域,不能与 Windows 身份验证一起使用。

来源:互联网 发布:360关闭网络防火墙 编辑:程序博客网 时间:2024/05/03 22:18

使用sql2008  远程连接数据库的时候遇到了这个问题,我用的是ADO.NET 实体数据模型,有app.config和web.config  解决了好久,因开始以为是sql的权限问题。后来解决了只需要在web.config中

<connectionStrings>
    <add name="ConnectionString" connectionString="Data Source=192.168.100.30;Initial Catalog=RsxCompany;Integrated Security=false;User ID=sa;Password=etm0802;MultipleActiveResultSets=True" providerName="System.Data.SqlClient"/>
  </connectionStrings>

将红色字体设为false

原创粉丝点击