I experience some issues when listing properties from childnodes. Here's an example:
IPublishedContent testroot = Umbraco.TypedContent(999); var somechildren = testroot.Children; foreach(IPublishedContent child in somechildren) { string myVal = child.GetPropertyValue<string>("myproperty"); //Do some stuff with myVal }
If I change the value of "myproperty"on some of the children, and publish that page. The old value still appears as "myVal". But, If I load every child again inside the loop, it works. Like this:
IPublishedContent testroot = Umbraco.TypedContent(999); var somechildren = testroot.Children; foreach(IPublishedContent child in somechildren) { var child2 = Umbraco.TypedContent(child.Id); string myVal = child2.GetPropertyValue<string>("myproperty"); }
What version of Umbraco are you using? It may or may not be a bug - but if you suspect that it is indeed a bug feel free to file an issue using the issue tracker.
Childcontent caching issues
I experience some issues when listing properties from childnodes. Here's an example:
If I change the value of "myproperty"on some of the children, and publish that page. The old value still appears as "myVal". But, If I load every child again inside the loop, it works. Like this:
Hi Calle
What version of Umbraco are you using? It may or may not be a bug - but if you suspect that it is indeed a bug feel free to file an issue using the issue tracker.
/Jan
is working on a reply...