3
votes

Another goofy one... trying to access existing content items originally created by an admin as a regular user but getting the following juicy exception. I can see the items in the content tree as this user, but the exception is thrown when I click on an item to view it (and presumably to edit it as the next step).

Server Error in '/' Application.

Null ids are not allowed. Parameter name: displayName

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.ArgumentNullException: Null ids are not allowed. Parameter name: displayName

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace:

[ArgumentNullException: Null ids are not allowed. Parameter name: displayName]
Sitecore.Diagnostics.Assert.ArgumentNotNullOrEmpty(String argument, String argumentName) +75
Sitecore.Shell.Applications.ContentEditor.EditorFormatter.RenderSectionBegin(Control parent, String controlId, String sectionName, String displayName, String icon, Boolean isCollapsed, Boolean renderFields) +69
Sitecore.Shell.Applications.ContentEditor.Pipelines.RenderContentEditor.RenderSkinedContentEditor.RenderSectionPanel(XmlNode element) +214
Sitecore.Shell.Applications.ContentEditor.Pipelines.RenderContentEditor.RenderSkinedContentEditor.RenderElement(XmlNode element) +487
Sitecore.Shell.Applications.ContentEditor.Pipelines.RenderContentEditor.RenderSkinedContentEditor.AddText(XmlNode element) +423
Sitecore.Shell.Applications.ContentEditor.Pipelines.RenderContentEditor.RenderSkinedContentEditor.RenderElement(XmlNode element) +533
Sitecore.Shell.Applications.ContentEditor.Pipelines.RenderContentEditor.RenderSkinedContentEditor.AddText(XmlNode element) +423
Sitecore.Shell.Applications.ContentEditor.Pipelines.RenderContentEditor.RenderSkinedContentEditor.RenderElement(XmlNode element) +533
Sitecore.Shell.Applications.ContentEditor.Pipelines.RenderContentEditor.RenderSkinedContentEditor.Render(XmlDocument skin) +93
Sitecore.Shell.Applications.ContentEditor.Pipelines.RenderContentEditor.RenderSkinedContentEditor.Process(RenderContentEditorArgs args) +353 (Object , Object[] ) +61
Sitecore.Pipelines.PipelineMethod.Invoke(Object[] parameters) +36
Sitecore.Pipelines.CoreProcessor.Invoke(Object[] parameters) +43
Sitecore.Pipelines.CorePipeline.Run(PipelineArgs args) +133
Sitecore.Pipelines.CorePipeline.Run(String pipelineName, PipelineArgs args, String pipelineDomain, Boolean failIfNotExists) +154
Sitecore.Pipelines.CorePipeline.Run(String pipelineName, PipelineArgs args, String pipelineDomain) +64
Sitecore.Pipelines.CorePipeline.Run(String pipelineName, PipelineArgs args) +50
Sitecore.Shell.Applications.ContentManager.Editor.Render(RenderContentEditorArgs args, Control parent) +450
Sitecore.Shell.Applications.ContentManager.Editor.Render(Item item, Item root, Hashtable fieldInfo, Control parent, Boolean showEditor) +239 Sitecore.Shell.Applications.ContentManager.ContentEditorForm.RenderEditor(Item item, Item root, Control parent, Boolean showEditor) +153
Sitecore.Shell.Applications.ContentManager.ContentEditorForm.UpdateEditor(Item folder, Item root, Boolean showEditor) +238
Sitecore.Shell.Applications.ContentManager.ContentEditorForm.Update() +249 Sitecore.Shell.Applications.ContentManager.ContentEditorForm.OnPreRendered(EventArgs e) +116

[TargetInvocationException: Exception has been thrown by the target of an invocation.]
System.RuntimeMethodHandle._InvokeMethodFast(IRuntimeMethodInfo method, Object target, Object[] arguments, SignatureStruct& sig, MethodAttributes methodAttributes, RuntimeType typeOwner) +0
System.RuntimeMethodHandle.InvokeMethodFast(IRuntimeMethodInfo method, Object target, Object[] arguments, Signature sig, MethodAttributes methodAttributes, RuntimeType typeOwner) +69
System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture, Boolean skipVisibilityChecks) +306
System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) +22 System.Reflection.MethodBase.Invoke(Object obj, Object[] parameters) +19
Sitecore.Reflection.ReflectionUtil.InvokeMethod(MethodInfo method, Object[] parameters, Object obj) +38
Sitecore.Reflection.ReflectionUtil.CallMethod(Type type, Object obj, String methodName, Boolean includeNonPublic, Boolean includeInherited, Boolean includeStatic, Object[] parameters) +104
Sitecore.Reflection.ReflectionUtil.CallMethod(Type type, Object obj, String methodName, Boolean includeNonPublic, Boolean includeInherited, Object[] parameters) +26
Sitecore.Reflection.ReflectionUtil.CallMethod(Object obj, String methodName, Boolean includeNonPublic, Boolean includeInherited, Object[] parameters) +41
Sitecore.Shell.Applications.ContentManager.ContentEditorPage.OnPreRender(EventArgs e) +87 System.Web.UI.Control.PreRenderRecursiveInternal() +150
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +2838

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

1
Can you see the item when you log in as the admin user?Craig Taylor
@CraigTaylor - When I log in as the admin, I can definitely see the item, but I can see it in the tree as the editor account too. Oh, I'll add this up top too, but I get the error when I click on the item to edit it.longda
Next time you get this error. Clear your cache and refresh the page.Gabbar

1 Answers

3
votes

So, I went back and removed any custom access rights set on the account (which resolved my issue) after finding the following answer:

A message that’s very long, but also not very helpful in finding a solution.

The only helpful thing I found was http://egointeractive.posterous.com/argumentnullexception-null-ids-are-not-allowe

Which mentions the same thing happening because of denied read rights on templates.

That did fix the problem, giving me another one – some fields on some templates shouldn’t be visible for specific users. Luckily the answer to that one was an easy one: All I needed to do was deny the Field Read right, rather than the Read right.

Reference: http://trayek.wordpress.com/2013/03/21/sitecore-content-editor-woes/

For posterity, here is the posterous (RIP) link in it's entirety:

[ArgumentNullException]: Null ids are not allowed. Parameter name: displayName I ran into this error after setting up a user with limited read/write permissions. I created a custom role, assigned 'Sitecore Client Author' and 'Sitecore Client User', assigned the user to the role, and checked that they could log in and see the content tree. Everything seemed fine, until I tried clicking on any of the items under 'Home'. On some occasions, one of two things happened: I got this error: [ArgumentNullException]: Null ids are not allowed. Parameter name: displayName Items that I knew ought to have fields, didn't I tried different combinations of roles (including dropping my custom role and using Sitecore's defaults only), but I still ran into problems - again, only on certain items. As far as I could tell, administrators were the only users able to see items, and there were no examples of working users without admin rights.

The website had recently been upgraded from Sitecore 5 (I'm not sure which version) to Sitecore 6.3.1 (rev. 110112), and as far as I know, it wasn't until after this point that the problem became apparent. I've seen the error before in almost exactly the same circumstances, so I would wager that it has something to do with the upgrade.

When I looked through the permissions for user-created templates (not system templates) permissions, I noticed that inheritance had been denied on section/field child items for quite a few templates. I couldn't see a reason why this should be the case, so I spent some time getting rid of the explicit deny (there were 50+ cases of it in this particular install) - hey presto, the error disappeared! I had to use the 'Remove Inherit' button in the Security Editor ribbon; using 'Assign' or unchecking the [ X ] next to the in 'Inheritance' permission for the item didn't work.

Reference: http://web.archive.org/web/20130317212504/http://egointeractive.posterous.com/argumentnullexception-null-ids-are-not-allowe