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 11: public partial class cBlokAktuality : System.Web.UI.UserControl, XwebInterface.IBlokAktualita
Line 12: {
Line 13:     public string culture = HttpContext.Current.Items["VychoziJazyk"].ToString();
Line 14: 
Line 15:     private string zkratkaMiniatura;

Source File: c:\webhosting\RMplast2021\cBlokAktuality.ascx.cs    Line: 13

Stack Trace:


[NullReferenceException: Object reference not set to an instance of an object.]
   cBlokAktuality..ctor() in c:\webhosting\RMplast2021\cBlokAktuality.ascx.cs:13
   ASP.cblokaktuality_ascx..ctor() in c:\Windows\Microsoft.NET\Framework64\v4.0.30319\Temporary ASP.NET Files\root\4fe1b301\99badbc7\App_Web_gsbu0db3.10.cs:0
   ASP.aktuality_aspx.__BuildControlBlokAktuality() in c:\webhosting\RMplast2021\Aktuality.aspx:9
   ASP.aktuality_aspx.__BuildControlContent2(Control __ctrl) in c:\webhosting\RMplast2021\Aktuality.aspx:7
   System.Web.UI.MasterPage.InstantiateInContentPlaceHolder(Control contentPlaceHolder, ITemplate template) +102
   ASP.masterpage_master.__BuildControlContentPlaceHolder1() in c:\webhosting\RMplast2021\MasterPage.master:46
   ASP.masterpage_master.__BuildControlform1() in c:\webhosting\RMplast2021\MasterPage.master:18
   ASP.masterpage_master.__BuildControlTree(masterpage_master __ctrl) in c:\webhosting\RMplast2021\MasterPage.master:1
   ASP.masterpage_master.FrameworkInitialize() in c:\webhosting\RMplast2021\MasterPage.master.cs:912307
   System.Web.UI.MasterPage.CreateMaster(TemplateControl owner, HttpContext context, VirtualPath masterPageFile, IDictionary contentTemplateCollection) +1178
   System.Web.UI.Page.get_Master() +64
   System.Web.UI.Page.ApplyMasterPage() +17
   System.Web.UI.Page.PerformPreInit() +61
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1109


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