Server Error in '/' Application.

Data is Null. This method or property cannot be called on Null values.

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.Data.SqlTypes.SqlNullValueException: Data is Null. This method or property cannot be called on Null values.

Source Error:


Line 123:                        Affiliate_ID = rs.GetInt32(11);
Line 124:                        Lang_ID = rs.GetInt32(14);
Line 125:                        Network_ID = rs.GetInt32(15);
Line 126:                        Regulatory_Title_Name = rs.GetString(7);
Line 127:                        Regulatory_Title_Name_fr = rs.GetString(16);

Source File: c:\inetpub\wwwroot\PRODUCTION\mortgageboss.ca\LeadGeneration\add_lead.aspx.cs    Line: 125

Stack Trace:


[SqlNullValueException: Data is Null. This method or property cannot be called on Null values.]
   System.Data.SqlClient.SqlBuffer.get_Int32() +2799306
   leadgeneration_add_lead.Page_Load(Object sender, EventArgs e) in c:\inetpub\wwwroot\PRODUCTION\mortgageboss.ca\LeadGeneration\add_lead.aspx.cs:125
   System.Web.UI.Control.OnLoad(EventArgs e) +106
   System.Web.UI.Control.LoadRecursive() +68
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +3785


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