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 24:     Sub Page_Load()
Line 25:         If Not Page.IsPostBack Then
Line 26:             iReferer = Request.ServerVariables("HTTP_REFERER").ToString
Line 27:             If iReferer <> String.Empty Then
Line 28:                 'Response.Write(Session("sReferer"))

Source File: C:\Clients\WebSites\National Campaign\thenationalcampaign.org\send-to-a-friend.aspx    Line: 26

Stack Trace:


[NullReferenceException: Object reference not set to an instance of an object.]
   ASP.send_to_a_friend_aspx.Page_Load() in C:\Clients\WebSites\National Campaign\thenationalcampaign.org\send-to-a-friend.aspx:26
   System.Web.Util.CalliHelper.ArglessFunctionCaller(IntPtr fp, Object o) +5
   System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +858603
   System.Web.UI.Control.OnLoad(EventArgs e) +99
   System.Web.UI.Control.LoadRecursive() +47
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1436


Version Information: Microsoft .NET Framework Version:2.0.50727.1433; ASP.NET Version:2.0.50727.1433