Server Error in '/' Application.

Sequence contains no elements

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: Sequence contains no elements

Source Error:


Line 88:         this._detailInfomationBusiness.GetInfomationByInfomationId(infoInfomationDataTable, base.Request.QueryString["InfomationID"]);
Line 89:         CategoryDataSet.CategoryDataTable categoryDataTable = new CategoryDataSet.CategoryDataTable();
Line 90:         this._detailInfomationBusiness.GetCategoryByCategory(categoryDataTable, infoInfomationDataTable.First<InfomationDataSet.InfoInfomationRow>().CategoryID);
Line 91:         if (string.IsNullOrEmpty(infoInfomationDataTable.First<InfomationDataSet.InfoInfomationRow>().SubCategoryID.ToString()))
Line 92:         {

Source File: c:\DATABASE_WEB_CODE\ISGMARD_Site\DetailInfomation.aspx.cs    Line: 90

Stack Trace:


[InvalidOperationException: Sequence contains no elements]
   System.Linq.Enumerable.First(IEnumerable`1 source) +446
   DetailInfomation.ViewTitleContent() in c:\DATABASE_WEB_CODE\ISGMARD_Site\DetailInfomation.aspx.cs:90
   DetailInfomation.Page_Load(Object sender, EventArgs e) in c:\DATABASE_WEB_CODE\ISGMARD_Site\DetailInfomation.aspx.cs:28
   System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) +25
   System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +42
   System.Web.UI.Control.OnLoad(EventArgs e) +132
   System.Web.UI.Control.LoadRecursive() +66
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +2428


Version Information: Microsoft .NET Framework Version:2.0.50727.9061; ASP.NET Version:2.0.50727.9062