Server Error in '/' Application.

Cannot perform runtime binding on a null reference

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: Microsoft.CSharp.RuntimeBinder.RuntimeBinderException: Cannot perform runtime binding on a null reference

Source Error:


Line 22: 				if (isNumber) {
Line 23: 					dynamic announcement = DB.GetRecord("select * from research_tracker_announcement where id=@a", announceid);
Line 24: 					announceItemTitle.InnerText = announcement.title.ToString();
Line 25: 					Page.Header.Title = "CDFA - Pierce's Disease Research - Announcement #" + announceid + " - " + announcement.Title.ToString();
Line 26: 

Source File: e:\apps-tfs\wwwother\piercesdisease.cdfa.ca.gov\Announcements.aspx.cs    Line: 24

Stack Trace:


[RuntimeBinderException: Cannot perform runtime binding on a null reference]
   CallSite.Target(Closure , CallSite , Object ) +148
   System.Dynamic.UpdateDelegates.UpdateAndExecute1(CallSite site, T0 arg0) +245
   CallSite.Target(Closure , CallSite , Object ) +264
   Announcements.Page_Load(Object sender, EventArgs e) in e:\apps-tfs\wwwother\piercesdisease.cdfa.ca.gov\Announcements.aspx.cs:24
   System.Web.UI.Control.OnLoad(EventArgs e) +108
   System.Web.UI.Control.LoadRecursive() +90
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1533


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