Are you trying to get specific nested content items from a content node?
Nested content items is not persisted as content, so you need to get the containing node, and find the content for the property using the nested content editor.
Well in this case I've a Content Node with a NestedContent property and what I'm trying to read from the database directly is the items (Nested Content Item) of this property.
Nested Content and ContentServices
Hi everyone,
I'm currently struggling with this: I need to get from the database a nested content item. What I'm doing so far is:
Guid ncItemKey = ncItem.GetKey();
IContent content = Services.ContentService.GetById(ncItemKey);
But the "content" is always returning null...
My question is: Who can i achieve this in the right way?
Thanks,
Hi Nuno
Are you trying to get specific nested content items from a content node?
Nested content items is not persisted as content, so you need to get the containing node, and find the content for the property using the nested content editor.
Hi Søren,
Well in this case I've a Content Node with a NestedContent property and what I'm trying to read from the database directly is the items (Nested Content Item) of this property.
Let me show you:
Ok, then you need to get the Portfolio Section node through the contentservice, and get the value of the Portfolio Content property.
IIRC the value of a Nested Content property is a Dictionary
is working on a reply...