0

I have 20 plus libraries that I need to set the default value (to the same value). The data is from the term store, I also need to do this for a site column.

Is there a tool or script to do this rather than edit each library individually?

1

You can use PowerShell scripting for this

Sample code

$spWeb = Get-SPWeb http://siteurl
$spList = $spWeb.GetListFromUrl("/Lists/ListName/AllItems.aspx")
$spField = $spList.Fields["Field Name"]
$spField.DefaultValue = "1;#Term Name" #1 is term ID
$spField.Update()

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.