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 30:         string lsUL = "";
Line 31:         string[] laUL = Request.UserLanguages;
Line 32:         for (int i = 0; i < laUL.Length; i++) lsUL += laUL[i] + " ";
Line 33:         lsUL = lsUL.TrimEnd();
Line 34:         string lsRef = "";

Source File: c:\inetpub\wwwroot\WebKarty\global.asax    Line: 32

Stack Trace:


[NullReferenceException: Object reference not set to an instance of an object.]
   ASP.global_asax.Session_OnStart() in c:\inetpub\wwwroot\WebKarty\global.asax:32

[TargetInvocationException: Exception has been thrown by the target of an invocation.]
   System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor) +0
   System.Reflection.RuntimeMethodInfo.UnsafeInvokeInternal(Object obj, Object[] parameters, Object[] arguments) +269
   System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) +146
   System.Reflection.MethodBase.Invoke(Object obj, Object[] parameters) +34
   System.Web.Util.ArglessEventHandlerProxy.Callback(Object sender, EventArgs e) +74
   System.Web.SessionState.SessionStateModule.CompleteAcquireState() +375
   System.Web.SessionState.SessionStateModule.BeginAcquireState(Object source, EventArgs e, AsyncCallback cb, Object extraData) +1257
   System.Web.AsyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +703
   System.Web.HttpApplication.ExecuteStepImpl(IExecutionStep step) +75
   System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +158


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