Server Error in '/' Application.

Object variable or With block variable not set.

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 variable or With block variable not set.

Source Error:


Line 234:                            strtable = strtable & dr.Item(1).ToString & "_" & cid & "-" & StrCompanyList & ".aspx'>"
Line 235:                            strtable = strtable & dr.Item(col).ToString
Line 236:                            strtable = strtable & "</a> (" & Catcount(0) & ") </li>"
Line 237:                        End If
Line 238:                    Else

Source File: D:\INETPUB\VHOSTS\tradepeak.com\httpdocs\Company_Profile.aspx.vb    Line: 236

Stack Trace:


[NullReferenceException: Object variable or With block variable not set.]
   Microsoft.VisualBasic.CompilerServices.Container..ctor(Object Instance) +1476151
   Microsoft.VisualBasic.CompilerServices.NewLateBinding.ObjectLateInvokeDefault(Object Instance, Object[] Arguments, String[] ArgumentNames, Boolean ReportErrors, Boolean[] CopyBack) +57
   Microsoft.VisualBasic.CompilerServices.NewLateBinding.LateIndexGet(Object Instance, Object[] Arguments, String[] ArgumentNames) +88
   Company_Profile.fill_LeftSidesubcat(String strsql, Int32 cid, String Strcatalog) in D:\INETPUB\VHOSTS\tradepeak.com\httpdocs\Company_Profile.aspx.vb:236
   Company_Profile.Page_Load(Object sender, EventArgs e) in D:\INETPUB\VHOSTS\tradepeak.com\httpdocs\Company_Profile.aspx.vb:62
   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