2009-04-21 55 views

回答

1

更新的網絡配置數據源標籤

Provider=Microsoft.ACE.OLEDB.12.0;Data Source=<<PATH Goes Here>>;Persist Security Info=False; 
0

connectionstring位於web.config文件中。

0

修改您的應用程序的web.config文件以重新定義LocalSqlServer連接字符串以指向數據庫。

<connectionStrings> 
    <remove name="LocalSqlServer"/> 
    <add name="LocalSqlServer" 
     connectionString="server=.;database=aspnetdb; 
     integrated security=sspi;"/> 
</connectionStrings> 

如果您的成員資格提供程序未指向「LocalSqlServer」,那麼您也可以在web.config中對其進行修改。

<membership> 
    <providers> 
    <remove name="AspNetSqlMembershipProvider"/> 
    <add name="AspNetSqlMembershipProvider" 
     type="System.Web.Security.SqlMembershipProvider, ..." 
     connectionStringName="LocalSqlServer" 
     enablePasswordRetrieval="false" 
     enablePasswordReset="true" 
     requiresQuestionAndAnswer="true" 
     applicationName="/" 
     requiresUniqueEmail="false" 
     passwordFormat="Hashed" 
     maxInvalidPasswordAttempts="5" 
     minRequiredPasswordLength="7" 
     minRequiredNonalphanumericCharacters="1" 
     passwordAttemptWindow="10" 
     passwordStrengthRegularExpression="" 
    /> 
    </providers> 
</membership> 
相關問題