Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
Using the new ApplicationContext.Current.Services.RelationService, I'm not seeing any way of retrieving IPublishedContent object sets. I see that it's possible to get IUmbracoEntity enumerables, but aren't these the slower read / write objects, like the Umbraco.Core.Models.ContentType?
Is there some way of easily getting IPublishedContent object sets?
This is old... not so good that it doesn't have a reply. I'm on 7.6.3 and ran into the same issue.
Trying to figure it out now.
FYI: I'm in controller.
Here is my solution (Blog Example). I extracted this method out of the controller and use in in a "Helper" class:
private static IEnumerable<BlogArticle> RelatedArticles(int id)
var umbracoHelper = new Umbraco.Web.UmbracoHelper(UmbracoContext.Current);
IList<BlogArticle> list = new List<BlogArticle>();
var service = ApplicationContext.Current.Services.RelationService;
foreach (var relation in service.GetByParentId(id))
is working on a reply...
Write your reply to:
Image will be uploaded when post is submitted