Can someone please help, I am very new to all of this? I used this template in Visual Web Developer Express 2008 and receive this error when I put the websie on the server.
The connection name 'ClubSiteDB' was not found in the applications configuration or the connection string is empty.
Description:
An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
The source code that generated this unhandled exception can only be shown when compiled in debug mode. To enable this, please follow one of the below steps, then request the URL:
1. Add a "Debug=true" directive at the top of the file that generated the error. Example:
<%@ Page Language="C#" Debug="true" %>
or:
2) Add the following section to the configuration file of your application:
Note that this second technique will cause all files within a given application to be compiled in debug mode. The first technique will cause only that particular file to be compiled in debug mode.
Important: Running applications in debug mode does incur a memory/performance overhead. You should make sure that an application has debugging disabled before deploying into production scenario.
Source Error:
Stack Trace:
[InvalidOperationException: The connection name 'ClubSiteDB' was not found in the applications configuration or the connection string is empty.]
System.Web.Compilation.ConnectionStringsExpressionBuilder.GetConnectionString(String connectionStringName) +2959805
ASP.default_aspx.__BuildControlSqlDataSource1() +96
ASP.default_aspx.__BuildControlContent1(Control __ctrl) +208
System.Web.UI.CompiledTemplateBuilder.InstantiateIn(Control container) +12
ASP.default_master.__BuildControlContentPlaceHolder1() +101
ASP.default_master.__BuildControlform1() +87
ASP.default_master.__BuildControlTree(default_master __ctrl) +193
ASP.default_master.FrameworkInitialize() +34
System.Web.UI.UserControl.InitializeAsUserControlInternal() +31
System.Web.UI.MasterPage.CreateMaster(TemplateControl owner, HttpContext context, VirtualPath masterPageFile, IDictionary contentTemplateCollection) +1980896
System.Web.UI.Page.get_Master() +48
System.Web.UI.Page.ApplyMasterPage() +18
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +543
nch101378
Member
1 Points
14 Posts
The connection name 'ClubSiteDB' was not found
Jul 21, 2010 11:56 PM|LINK
Can someone please help, I am very new to all of this? I used this template in Visual Web Developer Express 2008 and receive this error when I put the websie on the server.
The Web.Config page has this code:
<ConnectionStrings>add name="ClubSiteDB" connectionString="Data Source=.\SQLExpress;Integrated Security=true;AttachDBFileName=|DataDirectory|Club.mdf;User " providerName="System.Data.SqlClient"/>connectionStrings>
Server Error in '/' Application.
The connection name 'ClubSiteDB' was not found in the applications configuration or the connection string is empty.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Source Error:
Stack Trace:
luappy13
Participant
1874 Points
408 Posts
Re: The connection name 'ClubSiteDB' was not found
Jul 22, 2010 01:17 AM|LINK
NOTE: I use c#. this may be different for vb (Capitalised 'C' perhaps in connectionStrings)
The error was missing < at beggining of <add /> and </ missing from closing tag
nch101378
Member
1 Points
14 Posts
Re: The connection name 'ClubSiteDB' was not found
Jul 22, 2010 01:30 AM|LINK
I guess that fixed it, I have a new error now. Thank you for the quick response.
luappy13
Participant
1874 Points
408 Posts
Re: The connection name 'ClubSiteDB' was not found
Jul 22, 2010 01:30 AM|LINK
Kewl... can you mark as answer please and post your new error if you likeI see you marked sorry.