Server Error in '/' Application.

Index 0 is either negative or above rows count.

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.IndexOutOfRangeException: Index 0 is either negative or above rows count.

Source Error:


Line 18: 
Line 19:             //lblProductNameBreadcrumb.Text = dv[0]["ProductName"].ToString();
Line 20:             lblProductCategory.Text = dv[0]["ProductCategoryName"].ToString();
Line 21:             title = dv[0]["MetaTittle"].ToString();
Line 22:             description = dv[0]["MetaDescription"].ToString();

Source File: c:\website-2023\Pet-house.com.vn\chi-tiet-san-pham.aspx.cs    Line: 20

Stack Trace:


[IndexOutOfRangeException: Index 0 is either negative or above rows count.]
   System.Data.DataView.GetRow(Int32 index) +4880739
   System.Data.DataView.get_Item(Int32 recordIndex) +12
   chi_tiet_san_pham.Page_Load(Object sender, EventArgs e) in c:\website-2023\Pet-house.com.vn\chi-tiet-san-pham.aspx.cs:20
   System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) +14
   System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +35
   System.Web.UI.Control.OnLoad(EventArgs e) +99
   System.Web.UI.Control.LoadRecursive() +50
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +627


Version Information: Microsoft .NET Framework Version:2.0.50727.8974; ASP.NET Version:2.0.50727.8974