Reputation: 322
I'm working on Ektron CMS asp.net web forms(not mvc).
I want to get list of child taxonomies under parent taxonomy recursively.
Could anyone help me on this.
Upvotes: 0
Views: 42
Reputation: 149
This should work:
using Ektron.Cms.Framework.Organization;
using Ektron.Cms.Organization;
using System.Collections.Generic;
Code:
long parentID = 2147486197; // This is the parent taxonomy's ID
TaxonomyManager taxMan = new TaxonomyManager();
TaxonomyCriteria criteria = new TaxonomyCriteria();
criteria.AddFilter(TaxonomyProperty.ParentId, Ektron.Cms.Common.CriteriaFilterOperator.EqualTo, parentID);
List<Ektron.Cms.TaxonomyData> resultsList = taxMan.GetList(criteria);
Upvotes: 0