Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Lee 1130 posts 3088 karma points
    Jul 28, 2010 @ 17:33
    Lee
    0

    The given key was not present in the dictionary? Media Folders?

    Out of no where we are getting this error on Media folders only?  If you click on images they work fine, but click on a folder and I get the below

    The given key was not present in the dictionary.

    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.Collections.Generic.KeyNotFoundException: The given key was not present in the dictionary.

    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: 

    [KeyNotFoundException: The given key was not present in the dictionary.]
       System.ThrowHelper.ThrowKeyNotFoundException() +36
       System.Collections.Generic.Dictionary`2.get_Item(TKey key) +4292229
       umbraco.cms.businesslogic.datatype.controls.Factory.GetNewObject(Guid DataEditorId) in d:\TeamCity\buildAgent\work\7380c184e9fcd3ea\umbraco\cms\businesslogic\datatype\factory.cs:50
       umbraco.cms.businesslogic.datatype.controls.Factory.DataType(Guid DataTypeId) in d:\TeamCity\buildAgent\work\7380c184e9fcd3ea\umbraco\cms\businesslogic\datatype\factory.cs:40
       umbraco.cms.businesslogic.datatype.DataTypeDefinition.get_DataType() in d:\TeamCity\buildAgent\work\7380c184e9fcd3ea\umbraco\cms\businesslogic\datatype\DataType.cs:79
       umbraco.cms.businesslogic.datatype.DataTypeDefinition.GetByDataTypeId(Guid DataTypeId) in d:\TeamCity\buildAgent\work\7380c184e9fcd3ea\umbraco\cms\businesslogic\datatype\DataType.cs:239
       noerd.Umb.DataTypes.multipleFileUpload.MultipleFileUploadDataType.get_DataEditor() +70
       umbraco.controls.ContentControl.addControlNew(Property p, TabPage tp, String Caption) in d:\TeamCity\buildAgent\work\7380c184e9fcd3ea\umbraco\presentation\umbraco\controls\ContentControl.cs:211
       umbraco.controls.ContentControl..ctor(Content c, publishModes CanPublish, String Id) in d:\TeamCity\buildAgent\work\7380c184e9fcd3ea\umbraco\presentation\umbraco\controls\ContentControl.cs:81
       umbraco.cms.presentation.editMedia.OnInit(EventArgs e) in d:\TeamCity\buildAgent\work\7380c184e9fcd3ea\umbraco\presentation\umbraco\editMedia.aspx.cs:79
       System.Web.UI.Control.InitRecursive(Control namingContainer) +143
       System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1477

    As I say this has just happened out of nowhere? Site is running fine and all other sections in the main content tree are fine - Just the 'folders' in the media section.

  • Lee 1130 posts 3088 karma points
    Jul 28, 2010 @ 17:39
    Lee
    0

    Ok I have tied this up with the multiple file upload package which was installed... ( http://our.umbraco.org/projects/website-utilities/multiple-file-upload/bugs/7665-Uninstalling-package )

    I have uninstalled and I am now getting the following error 

    Object reference not set to an instance of an object.

    This is down to the property still being on the 'Media Folder' doctype..  BUT problem is when I try to remove the property I get another 

    Object reference not set to an instance of an object.

    Error!!  So how do I manually remove a property from a doctype if I can't do it in the editor??

  • Lee Kelleher 4020 posts 15802 karma points MVP 13x admin c-trib
    Jul 28, 2010 @ 17:51
    Lee Kelleher
    1

    Hi Lee,

    Run this SQL against your database, see what other properties are associated with the Folder media-type:

    SELECT * FROM cmsPropertyType WHERE contentTypeId = 1031

    You should be safe to delete the rows/properties that you don't want from here.  You might wanna back-up your database first... ya know, just in case! ;-)

    Cheers, Lee.

  • Lee 1130 posts 3088 karma points
    Jul 28, 2010 @ 17:59
    Lee
    0

    Thanks fella... Sorted... :)

Please Sign in or register to post replies

Write your reply to:

Draft