none
如何配置WebPart个性化数据库连接 RRS feed

答案

  • (1)比较简单,用局部设置覆盖全局设置 <connectionStrings> <remove name="LocalSqlServer" /> <add name="LocalSqlServer" connectionString="Data Source=localhost;Initial Catalog=aspnetdb;Persist Security Info=True;User ID=sa;Password=123456" providerName="System.Data.SqlClient" /> </connectionStrings>(2)新建一个设置: <connectionStrings> <add name="DataServer" connectionString="Server=(local);Trusted_Connection=true; Database

     

    2007年8月7日 8:46