I'm trying to pick up a node from supplied id so I use new Node() and new DynamicNode

However none of it is working. See the code:

@helper GetPriceRecursive(string nodeId)
{
    int ni = Convert.ToInt32(nodeId);
    umbraco.NodeFactory.Node node = new umbraco.NodeFactory.Node(ni);
    @nodeId
    @(ni)
    <i>a</i>
    @node.Id
    <i>b</i>
    umbraco.MacroEngines.DynamicNode node1 = new umbraco.MacroEngines.DynamicNode(ni);
    @node1.Id
}

@ni and @nodeId display correct numeric value, eg. 1700

But then @node.Id and @node1.Id display 0

I sue both in my UmbracoTemplatePage view

Any ideas?

Related posts

Recent Viewed