The website runs perfectly fine on my local computer. but when i upload it to the server.
and run the login or register button it says this
System.ComponentModel.Win32Exception: Access is denied
1. A network-related or instance-specific error occurred while establishing a connection to SQL Server.
2.The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: SQL Network Interfaces
3.error: 56 - Unable to load the SQLUserInstance.dll from the location specified in the registry. Verify that the Local Database Runtime feature of SQL Server Express is properly installed
could this be because the filter file in my local computer is this
<pre lang="c#"> [AttributeUsage(AttributeTargets.Class | AttributeTargets.Method, AllowMultiple = false, Inherited = true)]
public sealed class InitializeSimpleMembershipAttribute : ActionFilterAttribute
{
private static SimpleMembershipInitializer _initializer;
private static object _initializerLock = new object();
private static bool _isInitialized;
public override void OnActionExecuting(ActionExecutingContext filterContext)
{
LazyInitializer.EnsureInitialized(ref _initializer, ref _isInitialized, ref _initializerLock);
}
private class SimpleMembershipInitializer
{
public SimpleMembershipInitializer()
{
Database.SetInitializer<UsersContext>(null);
try
{
using (var context = new UsersContext())
{
if (!context.Database.Exists())
{
((IObjectContextAdapter)context).ObjectContext.CreateDatabase();
}
}
WebSecurity.InitializeDatabaseConnection("DefaultConnection", "UserProfile", "UserId", "UserName", autoCreateTables: true);
}
catch (Exception ex)
{
throw new InvalidOperationException("The ASP.NET Simple Membership database could not be initialized. For more information, please see http://go.microsoft.com/fwlink/?LinkId=256588", ex);
}
}
}
.
COULD THIS BE BECAUSE THE WEBSECURITY.INITIALISE DATABASECONNECTION CONTAINS THE DEFAULT CONNECTION OF MY LOCAL COMPUTER AND NOT OF THE SERVERS..IF SO CAN SOMEONE TELL ME HOW TO CHANGE IT
What I have tried:
I HAVE TRIED ADDING
under web.config
<system.web>
<customerrors mode="Off" />
</system.web>
for allowing remote connection
what should i do server side for the problem to be removed