Copied to clipboard

Flag this post as spam?

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


  • Richard Terris 273 posts 715 karma points
    Jan 07, 2013 @ 16:15
    Richard Terris
    0

    Razor files issue

    Hope someone can help me with this. 

    I installed uBlogsy into a 4.9 project but none of the Razor views are rendering.

    During investigation, when I try to save the uBlogsyListAuthors.cshtml file (without making any changes) I get the error:

    error CS1061: 'umbraco.MacroEngines.DynamicNode' does not contain a definition for 'GetPropertyValue' and no extension method 'GetPropertyValue' accepting a first argument of type 'umbraco.MacroEngines.DynamicNode' could be found (are you missing a using directive or an assembly reference?)

    adding this to the view makes no difference:

    @using umbraco.MacroEngines;

    the only change I have made to uBlogsy is within the struture, where I have allowed uBlogsyLanding document type to be a child of my siteSettings document type so I could move it - I moved the Root uBlogsy node and all children to sit underneath my siteSettings doc type, but I can't see why this would make any difference anyway.

    Any help will be very much appreciated

  • Richard Terris 273 posts 715 karma points
    Jan 07, 2013 @ 16:17
    Richard Terris
    0

    Further to this, it's definitely the correct umbraco.MacroEngines.dll file I have, and I've examined it in ILSpy; there are definitely methods for GetPropertyValue() in there

  • Sebastiaan Janssen 5060 posts 15522 karma points MVP admin hq
    Jan 07, 2013 @ 16:25
  • Richard Terris 273 posts 715 karma points
    Jan 07, 2013 @ 16:31
    Richard Terris
    0

    Changing:

    DynamicNode d = new DynamicNode(PageData[0]);

            <div class="uBlogsy_author">

                @if (!string.IsNullOrEmpty(@d.GetPropertyValue("uBlogsyPostAuthor")))

     

    To:

     

    dynamic d = new DynamicNode(PageData[0]);

     <div class="uBlogsy_author">

                @if (!string.IsNullOrEmpty(d.GetPropertyValue("uBlogsyPostAuthor")))

    DOES clear the error, but the view still won't render on the front end

  • Sebastiaan Janssen 5060 posts 15522 karma points MVP admin hq
    Jan 07, 2013 @ 16:32
    Sebastiaan Janssen
    0

    Obvious question: is the node's property uBlogsyPostAuthor just empty or null? :-)

  • Richard Terris 273 posts 715 karma points
    Jan 07, 2013 @ 16:38
    Richard Terris
    0

    No it's all still setup as out-the-box, I literally haven't changed a thing other than moving the location.

    But see these dumps of front and back end

    If you have trouble seeing them I'll mail them to you but it all seems set up as normal, but I ALWAYS assume it's something I've either done or not done - as it usually is :)

  • Richard Terris 273 posts 715 karma points
    Jan 07, 2013 @ 16:41
    Richard Terris
    0

    it does seem odd that all of these scripts would fail at once

  • Sebastiaan Janssen 5060 posts 15522 karma points MVP admin hq
    Jan 07, 2013 @ 16:45
    Sebastiaan Janssen
    0

    Try republishing all of the nodes including children.

    Also, if this is 4.10+, try touching the global.asax file (just add a space and save it). Could be that the macroengines cache is in a weird state. Please try this one by one so you can pinpoint the actual problem.

  • Richard Terris 273 posts 715 karma points
    Jan 07, 2013 @ 16:51
    Richard Terris
    0

    Ahead of you (for the first time ever!) just tried republishing but no dice

    It's 4.9.1 so no global.asax file

    I checked the umbraco.config file too and it's definitely in there

  • Richard Terris 273 posts 715 karma points
    Jan 07, 2013 @ 16:53
    Richard Terris
    0

    I don't need to set the rendering engine to razor in web.config do I?

  • Richard Terris 273 posts 715 karma points
    Jan 07, 2013 @ 17:23
    Richard Terris
    0

    Also tried moving this to root level, it was the only change I had made and I wondered if it was unable to determine the landing node because of the move.

    This hasn't made any difference to this issue

  • Sebastiaan Janssen 5060 posts 15522 karma points MVP admin hq
    Jan 07, 2013 @ 18:09
    Sebastiaan Janssen
    0

    So umbDebugShowTrace=true still shows the same error? Or a different one?

  • Richard Terris 273 posts 715 karma points
    Jan 08, 2013 @ 12:00
    Richard Terris
    0

    Sorry dude, I didn't get an email notification that you'd responded...

    trace shows: Error Loading Razor Script (file: uBlogsy - List Posts) Field not found: 'umbraco.MacroEngines.DynamicNodeList.Items'.    at uBlogsy.BusinessLogic.PostService.GetDescendentsOrSelf(Int32 nodeId, String targetAlias, IEnumerable`1 stopAliases)

  • Richard Terris 273 posts 715 karma points
    Jan 08, 2013 @ 12:02
    Richard Terris
    0

    none of the scripts are working, so basically the same error on each:

    Error Loading Razor Script (file: uBlogsy - List Authors) Field not found: 'umbraco.MacroEngines.DynamicNodeList.Items'.    at uBlogsy.BusinessLogic.PostService.GetDescendentsOrSelf(Int32 nodeId, String targetAlias, IEnumerable`1 stopAliases)

  • Richard Terris 273 posts 715 karma points
    Jan 08, 2013 @ 12:31
    Richard Terris
    0

    Just found this post http://our.umbraco.org/projects/starter-kits/ublogsy/ublogsy-bugs/24272-Errors-with-v136-on-a-470-install- where Anthony is saying not to use v2 as it's in beta.

    The post is from September 2011 and this is the version that's in the package repository

    Are there still issues with this?

  • Stephen Davidson 216 posts 392 karma points
    Jan 08, 2013 @ 13:10
    Stephen Davidson
    0

    Hey there...coming into this late i know so please ignore my ignorance.  Looking at your errors I had similar issue when I had added the blog via the Umbraco Package Repository rather than downloading the latest version and then "install local package".

    On that note which package version does it say is installed?

    I've been using V2 of several project without issue and I remember seeing the post above but I think it no longer applies.

    S

  • Richard Terris 273 posts 715 karma points
    Jan 08, 2013 @ 13:21
    Richard Terris
    0

    Hi Stephen

    I uninstalled uBlogsy and installed from a local .zip but same issue I'm afraid.

    It's version 2.1.1.1 and it's umbraco 4.9.1

    Running out of suggestions - Anthony suggested a fresh Umbraco install but this is a from-scratch app so it is a fresh install

  • Stephen Davidson 216 posts 392 karma points
    Jan 08, 2013 @ 13:26
    Stephen Davidson
    0

    have you tried creating the blog step by step? level by level?

    S

  • Richard Terris 273 posts 715 karma points
    Jan 08, 2013 @ 13:29
    Richard Terris
    0

    No I was just trying to view it as it comes, since there's some posts and other things already in place

    Do you think trying to create some manual posts might be worth a shot?

    incidentally, I also created uBlogsyListAuthors.cshtml as opposed to uBlogsy\uBlogsyListAuthors.cshtml and changed the macro but that didn't change anything either, so it's definitely an issue with the actual script files in some way, just can't figure out what

  • Stephen Davidson 216 posts 392 karma points
    Jan 08, 2013 @ 13:45
    Stephen Davidson
    0

    To be honest i clutching at straws there! Another thought i had was that the scripts files have been moved in later versions, into there own folder...presume the folder permission have all been setup?

    The following site is running the same version of Umbraco and Ublgosy...happy to give you access if you think it might help?

    http://www.cowglensportsclub.com

    S

     

  • Richard Terris 273 posts 715 karma points
    Jan 08, 2013 @ 13:48
    Richard Terris
    101

    Re-installing Umbraco seems to have fixed it.

    Thanks for your help - not really sure who's post to mark as the answer... guess I'll do my own in case anyone else hits this

Please Sign in or register to post replies

Write your reply to:

Draft