Opening the 'Insert image' modal in Umbraco 6.1.3 causes NullReferenceException

StackOverflow https://stackoverflow.com/questions/18248669

  •  24-06-2022
  •  | 
  •  

Domanda

When I hit the 'Insert image' button in the rich text editor bar, the modal opens but then an error page appears:

Details of exception: System.NullReferenceException: Object reference not set to an instance of an object

Stacktrace:
[NullReferenceException: De objectverwijzing is niet op een exemplaar van een object ingesteld.]
umbraco.controls.Images.ImageViewer.OnPreRender(EventArgs e) +70
System.Web.UI.Control.PreRenderRecursiveInternal() +83
System.Web.UI.Control.PreRenderRecursiveInternal() +168
System.Web.UI.Control.PreRenderRecursiveInternal() +168
System.Web.UI.Control.PreRenderRecursiveInternal() +168
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +974

Versiondata: Microsoft .NET Framework Versie:4.0.30319; ASP.NET Versie:4.0.30319.17929 

Running Umbraco 6.1.3 on localhost and on server, both give the error. I have already tried to replace the umbraco.dll and umbraco.editorControls.dll with fresh ones, but to no avail. I also checked all my datatypes, but none are corrupt (as per Rich Text Editor and Inserting Images getting error and http://our.umbraco.org/forum/using/ui-questions/39103-Problem-with-Rich-Text-Editor-and-Inserting-Images). I am using uComponents, but I have the most recent version (5.5.0)

È stato utile?

Soluzione

If this is an update from a previous version, check that the configuration settings are all present, especially any specific to the media folder. It sounds like a setting just isn't present.

Also, often I forget to "include" all the files in my visual studio project too, so when I do a publish, any new files don't get included.

Altri suggerimenti

I got this error when I upgraded an install from v6.1.1 to v6.1.6. Although the offcial instructions state that only the bin folder needs to be updated this is far from being the case. You also need to ensure you use the latest files under /Umbraco and also /Umbraco_client. If you check the namespaces in /Umbraco/Controls/Images, for example you'll see it now lives in a different namespace

'<%@ Control Language="C#" AutoEventWireup="True" CodeBehind="ImageViewer.ascx.cs" Inherits="Umbraco.Web.UI.Umbraco.Controls.Images ... %>

to the original:

'<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="ImageViewer.ascx.cs" Inherits="umbraco.controls.Images.ImageViewer" %>'

I've been working with Umbraco for just over six months and in that time I've yet to see a document from them that is accurate or complete. FFS.

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top