Copied to clipboard

Flag this post as spam?

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


  • jake williamson 207 posts 872 karma points
    Nov 22, 2017 @ 11:55
    jake williamson
    0

    help! my MultiNodeTreePicker isn't returning as 'IEnumerable<IPublishedContent>'

    hey out there,

    i've got a umbraco project that was recent upgraded from v7.2.6 to v7.7.2.

    there's a load of datatypes based on the 'Umbraco.MultiNodeTreePicker' property which displays as '(Obsolete) Multinode Treepicker' in the 'property editor' select.

    i've experimented with changing these to the 'Umbraco.MultiNodeTreePicker2' property editor but it blows away the selections...

    the problem i have now is that i need to add a new datatype and i've based it on the 'Umbraco.MultiNodeTreePicker2' property editor. when i debug the code, it's not returning as 'IEnumerable

    the below watch grab shows the data being returned for a property based on the 'Umbraco.MultiNodeTreePicker' and the 'Umbraco.MultiNodeTreePicker2':

    enter image description here

    the 1st one is returning the id of the selected node '1438'. the 2nd one is returning 'umb' links in a csv 'umb://document/2ca28e5729dc47e7b66f1ab90bec8820,umb://document/7f03a200d1b046fb83781444131f2735'.

    using this code on the 1st property works but using it on the 2nd property returns nothing:

    var quotes = t.GetPropertyValue<IEnumerable<IPublishedContent>>("quotes");
    

    this is a bit of a nightmare! has anyone any idea what's going on here?! one route i can see out of this is to change the 2nd datatype to be based on the 'Umbraco.MultiNodeTreePicker' property but this isn't possible due to it not being the select list!

    help?!

  • jake williamson 207 posts 872 karma points
    Nov 22, 2017 @ 14:23
    jake williamson
    100

    well, after a whole heap of debugging and mucking around the solution was to resave the entire site.

    once i did that, i then get an IEnumerable of IPublishedContent back.

    i'm now off to bang my head against the wall with something else...

Please Sign in or register to post replies

Write your reply to:

Draft