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 32:         Dim Bike As New clsAssetItem(BikeID)
Line 33: 
Line 34: 		litBikeEnquire.Text = "<a href=" & GetXMLSiteProps(Me,"SITE_URL") & "enquire/used-bike/" & BikeID &"/" & Bike.Name.Replace(" ","-").ToLower & " class=""expand button used-model-enquire""><i class=""fa fa-envelope-o""></i> Make an Enquiry</a>"
Line 35: 		
Line 36:         litModelName.Text = Bike.Name

Source File: C:\inetpub\wwwroot\Applications\ContentManagedSites\Waltham-Cross-Motorcycles-iVendi-Finance\Live\view-used-bike.aspx.vb    Line: 34

Stack Trace:


[NullReferenceException: Object reference not set to an instance of an object.]
   view_used_bike.ShowBike(Int32 BikeID) in C:\inetpub\wwwroot\Applications\ContentManagedSites\Waltham-Cross-Motorcycles-iVendi-Finance\Live\view-used-bike.aspx.vb:34
   view_used_bike.Page_Load(Object sender, EventArgs e) in C:\inetpub\wwwroot\Applications\ContentManagedSites\Waltham-Cross-Motorcycles-iVendi-Finance\Live\view-used-bike.aspx.vb:26
   System.Web.UI.Control.OnLoad(EventArgs e) +95
   System.Web.UI.Control.LoadRecursive() +59
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +678


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