PDA

View Full Version : مشکل با aspnet_regsql.exe



gggggggg
پنج شنبه 14 مهر 1390, 12:18 عصر
سلام.
من یه سایت نوشتم که از asp 4 و sqlsever 2008 استفاده میکنم.
من برای صفحات لاگین و ثبت نام سایتم از aspnet_regsql.exe استفاده کردم.
وقتی که سایت رو با ویژوال استدیو و روی سیستم خودم ران میکنم مشکلی نیست هم می تونم لاگین کنم هم ثبت نام اما وقتی سایت رو اپلود میکنم و میخوام لاگین یا ثبت نام انجام بدم این ارر رو میده:



The 'System.Web.Security.SqlMembershipProvider' requires a database schema compatible with schema version '1'. However, the current database schema is not compatible with this version. You may need to either install a compatible schema with aspnet_regsql.exe (available in the framework installation directory), or upgrade the provider to a newer version.


این هم از تنظیمات web.config


<?xml version="1.0"?>
<!--
For more information on how to configure your ASP.NET application, please visit
http://go.microsoft.com/fwlink/?LinkId=169433
-->
<configuration>
<connectionStrings>
<clear/>
<add name="LocalSQLServer" connectionString="Data Source=Mahdi-PC;Initial Catalog=Shop1;Integrated Security=True"/>
<add name="CS" connectionString="Data Source=Mahdi-PC;Initial Catalog=Shop1;Integrated Security=True" providerName="System.Data.SqlClient"/>
<add name="ApplicationServices" connectionString="Data Source=Mahdi-PC;Initial Catalog=Shop1;Integrated Security=True" providerName="System.Data.SqlClient"/>
</connectionStrings>
<system.web>
<authorization>
<allow roles="Admin" />
</authorization>
<compilation debug="true" targetFramework="4.0">
<assemblies>
<add assembly="System.Design, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
<add assembly="System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/></assemblies></compilation>
<authentication mode="Forms">
<forms loginUrl="~/Account/Login.aspx" timeout="2880"/>
</authentication>
<membership>
<providers>
<clear/>
<add name="AspNetSqlMembershipProvider" type="System.Web.Security.SqlMembershipProvider" connectionStringName="ApplicationServices" enablePasswordRetrieval="false" enablePasswordReset="true" requiresQuestionAndAnswer="false" requiresUniqueEmail="false" maxInvalidPasswordAttempts="5" minRequiredPasswordLength="6" minRequiredNonalphanumericCharacters="0" passwordAttemptWindow="10" applicationName="/froshgah2"/>
</providers>
</membership>
<profile>
<providers>
<clear/>
<add name="AspNetSqlProfileProvider" type="System.Web.Profile.SqlProfileProvider" connectionStringName="ApplicationServices" applicationName="/froshgah2"/>
</providers>
</profile>
<roleManager enabled="true">
<providers>
<clear />
<add connectionStringName="ApplicationServices" applicationName="/"
name="AspNetSqlRoleProvider" type="System.Web.Security.SqlRoleProvider" />
<add applicationName="/" name="AspNetWindowsTokenRoleProvider"
type="System.Web.Security.WindowsTokenRoleProvider" />
</providers>
</roleManager>
</system.web>
<system.webServer>
<modules runAllManagedModulesForAllRequests="true"/>
</system.webServer>
</configuration>

Saman Hashemi
شنبه 16 مهر 1390, 08:20 صبح
یه بار دیگه اینکار با استفاده از مسیر زیر امتحان کنید...!

C:\WINDOWS\Microsoft.NET\Framework\v4.0.30319\aspn et_regsql.exe