Server Error in '/' Application.

The connection name 'con' 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.

Exception Details: System.InvalidOperationException: The connection name 'con' was not found in the applications configuration or the connection string is empty.

Source Error:


Line 31:                         <SelectedItemStyle BorderStyle="Dashed" />
Line 32:                     </asp:DataList>
Line 33:                     <asp:SqlDataSource ID="SqlDataSource2" runat="server" 
Line 34:                         ConnectionString="<%$ ConnectionStrings:con %>" 
Line 35:                         ProviderName="<%$ ConnectionStrings:con.ProviderName %>">

Source File: g:\pleskvhosts\theroyaltrading.net\httpdocs\products.aspx    Line: 33

Stack Trace:


[InvalidOperationException: The connection name 'con' was not found in the applications configuration or the connection string is empty.]
   System.Web.Compilation.ConnectionStringsExpressionBuilder.GetConnectionString(String connectionStringName) +1904581
   ASP.products_aspx.__BuildControlSqlDataSource2() in g:\pleskvhosts\theroyaltrading.net\httpdocs\products.aspx:33
   ASP.products_aspx.__BuildControlContent2(Control __ctrl) in g:\pleskvhosts\theroyaltrading.net\httpdocs\products.aspx:5
   System.Web.UI.MasterPage.InstantiateInContentPlaceHolder(Control contentPlaceHolder, ITemplate template) +108
   ASP.masterpagecommon_master.__BuildControlContentPlaceHolder1() in g:\pleskvhosts\theroyaltrading.net\httpdocs\MasterPageCommon.master:76
   ASP.masterpagecommon_master.__BuildControlform1() in g:\pleskvhosts\theroyaltrading.net\httpdocs\MasterPageCommon.master:29
   ASP.masterpagecommon_master.__BuildControlTree(masterpagecommon_master __ctrl) in g:\pleskvhosts\theroyaltrading.net\httpdocs\MasterPageCommon.master:1
   ASP.masterpagecommon_master.FrameworkInitialize() in g:\pleskvhosts\theroyaltrading.net\httpdocs\MasterPageCommon.master.cs:912308
   System.Web.UI.MasterPage.CreateMaster(TemplateControl owner, HttpContext context, VirtualPath masterPageFile, IDictionary contentTemplateCollection) +1322
   System.Web.UI.Page.get_Master() +66
   System.Web.UI.Page.ApplyMasterPage() +19
   System.Web.UI.Page.PerformPreInit() +65
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +335


Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.8.4700.0