Skip to content

Get Object.Label of Managed Metadata #595

Answered by jansenbe
LegendaryB asked this question in Q&A
Discussion options

You must be logged in to vote

@LegendaryB , when reading the list holding the items I assume you've also loaded the list fields as mentioned here https://pnp.github.io/pnpcore/using-the-sdk/listitems-intro.html#reading-list-items? If so then a managed metadata field should be represented by an IFieldTaxonomyValue or an IFieldValueCollection of IFieldTaxonomyValue for multi taxonomy fields. Which should give you the taxonomy label and id (https://pnp.github.io/pnpcore/api/PnP.Core.Model.SharePoint.IFieldTaxonomyValue.html).

Now you can also simply split the string yourselves (label = Foo, Id = b704...)...

Replies: 1 comment 25 replies

Comment options

You must be logged in to vote
25 replies
@jansenbe
Comment options

@LegendaryB
Comment options

@jansenbe
Comment options

@LegendaryB
Comment options

@jansenbe
Comment options

Answer selected by LegendaryB
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants