Server Error in '/' Application.

The DataSourceID of 'rpt_stores' must be the ID of a control of type IDataSource.  A control with ID 'sql_stores' could not be found.

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.Web.HttpException: The DataSourceID of 'rpt_stores' must be the ID of a control of type IDataSource.  A control with ID 'sql_stores' could not be found.

Source Error:


Line 31:                         {
Line 32:                             div_store.Visible = true;
Line 33:                             rpt_stores.DataBind();
Line 34:                         }
Line 35:                     }

Source File: C:\Inetpub\vhosts\infobusiness.ir\httpdocs\Sub\Information_Legal.aspx.cs    Line: 33

Stack Trace:


[HttpException (0x80004005): The DataSourceID of 'rpt_stores' must be the ID of a control of type IDataSource.  A control with ID 'sql_stores' could not be found.]
   System.Web.UI.WebControls.Repeater.ConnectToDataSourceView() +2190947
   System.Web.UI.WebControls.Repeater.GetData() +20
   System.Web.UI.WebControls.Repeater.CreateControlHierarchy(Boolean useDataSource) +208
   System.Web.UI.WebControls.Repeater.OnDataBinding(EventArgs e) +62
   System.Web.UI.WebControls.Repeater.DataBind() +77
   Sub_Information_Legal.Page_Load(Object sender, EventArgs e) in C:\Inetpub\vhosts\infobusiness.ir\httpdocs\Sub\Information_Legal.aspx.cs:33
   System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +51
   System.Web.UI.Control.OnLoad(EventArgs e) +95
   System.Web.UI.Control.LoadRecursive() +59
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +678


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