Server Error in '/' Application.

Object reference not set to an instance of an object.

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.NullReferenceException: Object reference not set to an instance of an object.

Source Error:


Line 238:        if (strOpStylePage != "ProductDetail" && strOpStylePage != "chi-tiet-tin-tuc")
Line 239:        {
Line 240:            foreach (DataRow dr in dtListTagAllSite.Rows) strTag.AppendFormat(" <a href=\"{0}\" title=\"{1}\">{1}</a>, ", Common.LinkReturn(dr["Link"], dr["LinkOut"], ""), dr["Name"]);
Line 241:        }
Line 242:        if (strTag.Length > 0) strTagFooter.AppendFormat("<div class=\"item-tag-footer\"><span>Tag quan tâm: </span> {0}</div>", strTag.ToString().TrimEnd().TrimEnd(','));

Source File: d:\vhost\website\hachiha.vn\Index.aspx.cs    Line: 240

Stack Trace:


[NullReferenceException: Object reference not set to an instance of an object.]
   Index.GetDataSEO() in d:\vhost\website\hachiha.vn\Index.aspx.cs:240
   ASP.index_aspx.__Render__control1(HtmlTextWriter __w, Control parameterContainer) in d:\vhost\website\hachiha.vn\Index.aspx:6
   System.Web.UI.Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children) +275
   System.Web.UI.Page.Render(HtmlTextWriter writer) +39
   System.Web.UI.Control.RenderControlInternal(HtmlTextWriter writer, ControlAdapter adapter) +79
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +4562


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