How could I disable a managed metadata field?. I'm pulling the information of that field from another List and I don't want the user to modify its value
- Can you explain a bit more? You mean you want user to only read data from the list?Amal Hashim– Amal Hashim2015-04-16 21:42:29 +00:00Commented Apr 16, 2015 at 21:42
- I don't want the user modify the values I'm setting in that fieldyngrdyn– yngrdyn2015-04-17 01:43:02 +00:00Commented Apr 17, 2015 at 1:43
- Can't you disable the field by making it read only?Amal Hashim– Amal Hashim2015-04-17 01:44:38 +00:00Commented Apr 17, 2015 at 1:44
- No i can't. Because it's a Managed Metadata field. So i don't know well what do i have to make read only, there certains divs and things that Sharepoint creates to managed this kind of fieldyngrdyn– yngrdyn2015-04-17 03:28:33 +00:00Commented Apr 17, 2015 at 3:28
Add a comment |
2 Answers
You can make the MMD field hidden, through PowerShell
- Can you please add more details about how to do this?Robert Lindgren– Robert Lindgren2015-04-17 08:35:20 +00:00Commented Apr 17, 2015 at 8:35
function Get-TermSet([string]$groupName, [string]$termSetName) { $termStore = Get-TermStoreDefault return $termStore.Groups[$groupName].TermSets[$termSetName] } $termSet = Get-TermSet $yourtermStorGroupName $yourtermSetName $taxoField = $yourweb.Fields.CreateNewField("TaxonomyFieldType", $displayName) taxoField.SspId = $termSet.TermStore.Id taxoField.TermSetId = $termSet.Id taxofield.AllowMultipleValues = $false taxofield.Group = $fieldGroup taxofield.StaticName = $staticName taxofield.ShowInEditForm = $false #here is the solution taxofield.ShowInNewForm = $false #here is the solution taxofield.Hidden = $true #here is the solution taxofield.Required = $false $web.Fields.Add($taxofield); $web.Update();