I finally got my website to run on the local machine. I thought it was going to run on the server but I just get my login. After I enter my info and click "login" I get the following error. Do I need to enable the SQL Server Browser service?
Server Error in '/' Application.
Configuration Error
Description:An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.
Parser Error Message:The connection name 'LocalSqlServer' was not found in the applications configuration or the connection string is empty.
Source Error:
Line 138: <providers>Line 139: <add name="AspNetSqlMembershipProvider"Line 140: type="System.Web.Security.SqlMembershipProvider, System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"Line 141: connectionStringName="LocalSqlServer"Line 142: enablePasswordRetrieval="false"
Source File:C:\WINNT\Microsoft.NET\Framework\v2.0.50727\Config\machine.config Line:140
Version Information: Microsoft .NET Framework Version:2.0.50727.42; ASP.NET Version:2.0.50727.210
Perhaps, but that isn't what is causing the error. You haven't configured a connection string with the name "LocalSqLServer".
|||Do I do this in the solutions web config file?
|||Yes
|||Here is my web.config so far. I've tried putting the add tag and assigning LocalSqlServer to the default provider but I can't get anything to work. So what exactly do I need to do and where?
Thanks,
Nick
<?xmlversion="1.0"?>
<configurationxmlns="http://schemas.microsoft.com/.NetConfiguration/v2.0">
<connectionStrings><addname="ConnectionString"connectionString="Provider=Microsoft.Jet.OLEDB.4.0;Data Source=|DataDirectory|\OpenAssess.mdb;Persist Security Info=True"providerName="System.Data.OleDb"/>
</connectionStrings><system.web>
<traceenabled="true"requestLimit="15" /><authenticationmode="Forms"/>
<roleManagerenabled="true"/><compilationdebug="true"/>
</system.web></configuration>
|||Can I make this connectin straight to Access with out using sql at all? Our host server doesn't support SQL Server.
Thanks,
Nick
|||Looks like you are using the built-in Login controls. they use SQL Server 2005 Express by default, not access.
SQL Server 2005 Express is a free download from the same place as VWD EXpress, why not just use it?
|||Where is your aspnetdb going to be?
|||ASPNETDB.MDF is in my App_Data folder. I was trying to avoid SQL Server because the server we are on does not support it and I am trying to input data from the website to a database. Do you recommend we buy a package that supports it? I have SQL Server Management Studio Express on my local machine.
Thanks,
Nick
|||These are things wrong so far:
Your web.config file does not turn membership on.
Your web.config file does not have a membership provider defined (Which is fine if you want to use the default one).
You do not have a connection string that the default membership provider is configured to use (LocalSqlServer) defined in the connection strings section.
Apparently your host doesn't support Sql Server, yet you are trying to use a .MDB file (That's a Sql Server file). Perhaps you meant that your host only supports Sql Server Express (BTW, that's backwards from most hosting services -- Most support Sql Server but not Sql Server Express).
No comments:
Post a Comment