Server Error in '/' Application.

Conversion from type 'DBNull' to type 'String' is not valid.

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.InvalidCastException: Conversion from type 'DBNull' to type 'String' is not valid.

Source Error:


Line 68:         Else
Line 69:             If dt.Rows.Count > 0 Then
Line 70:                 If InStr(dt.Rows(0)("fldIntro"), "[[table-to-show]]") > 0 Then
Line 71:                     Return True
Line 72:                 End If

Source File: D:\inetpub\webs\comunetrigolocrit\procedures\transparency.aspx.vb    Line: 70

Stack Trace:


[InvalidCastException: Conversion from type 'DBNull' to type 'String' is not valid.]
   Microsoft.VisualBasic.CompilerServices.Conversions.ToString(Object Value) +1307492
   procedures_transparency.TableToShow() in D:\inetpub\webs\comunetrigolocrit\procedures\transparency.aspx.vb:70
   procedures_transparency.page_load(Object obj, EventArgs e) in D:\inetpub\webs\comunetrigolocrit\procedures\transparency.aspx.vb:44
   System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +52
   System.Web.UI.Control.OnLoad(EventArgs e) +97
   System.Web.UI.Control.LoadRecursive() +61
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +693


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