Set default value taxonomy field - published from CT hub - spo

%3CLINGO-SUB%20id%3D%22lingo-sub-6898%22%20slang%3D%22en-US%22%3ESet%20default%20value%20taxonomy%20field%20-%20published%20from%20CT%20hub%20-%20spo%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-6898%22%20slang%3D%22en-US%22%3E%3CP%3EHi%2C%3C%2FP%3E%3CP%3EI%20am%20looking%20for%20sample%20csom%20code%20which%20I%20can%20set%20default%20value%20of%20a%20taxonomy%20field%20which%20gets%20published%20from%20CT%20hub.%20I%20have%20managed%20to%20do%20this%20on%20a%20taxonomy%20field%20which%20is%20not%20linked%20with%20a%20content%20type%20published%20from%20CT%20hub.%20I%20cannot%20set%20the%20ddefault%20value%20at%20CT%20hub%2C%20since%20the%20defaut%20value%20is%20different%20at%20list%20level.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThanks%2C%3C%2FP%3E%3CP%3EKolitha%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-6933%22%20slang%3D%22en-US%22%3ERe%3A%20Set%20default%20value%20taxonomy%20field%20-%20published%20from%20CT%20hub%20-%20spo%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-6933%22%20slang%3D%22en-US%22%3E%3CP%3EHi%20Kolitha%2C%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3Ei%20think%20this%20code%20might%20help%20you%3A%26nbsp%3B%3CA%20href%3D%22http%3A%2F%2Fwww.sharepointdoug.com%2F2014%2F01%2Fprogrammatically-provisioning-term-sets.html%22%20target%3D%22_blank%22%20rel%3D%22nofollow%20noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttp%3A%2F%2Fwww.sharepointdoug.com%2F2014%2F01%2Fprogrammatically-provisioning-term-sets.html%3C%2FA%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3Elook%20for%20the%20anchorfield%20currently%20i%20use%20pnp%20to%20provision%20and%20set%20default%20metadata.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EKr%2C%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EPaul%3C%2FP%3E%3C%2FLINGO-BODY%3E
Highlighted
Occasional Contributor

Hi,

I am looking for sample csom code which I can set default value of a taxonomy field which gets published from CT hub. I have managed to do this on a taxonomy field which is not linked with a content type published from CT hub. I cannot set the ddefault value at CT hub, since the defaut value is different at list level.

 

Thanks,

Kolitha

1 Reply
Highlighted

Hi Kolitha,

 

i think this code might help you: http://www.sharepointdoug.com/2014/01/programmatically-provisioning-term-sets.html

 

look for the anchorfield currently i use pnp to provision and set default metadata.

 

Kr,

 

Paul