Friday, 13 September 2013

SharePoint 2013 TaxonomyFieldType in custom list has IsTermSetValid = False

SharePoint 2013 TaxonomyFieldType in custom list has IsTermSetValid = False

I'm using Visual Studio 2012 to create a custom Site Column of type
TaxonomyFieldType, a custom content type that uses it, and a custom list
that uses the content type.
Everything appears to deploy fine. If I look at my custom site column it
appears to reference the proper termset correctly. I can create a new list
in the web UI that uses my custom content type just fine. However, my
custom list created using the Visual Studio 2012 List template always
shows my taxonomy field as disabled on the new form. Here are the other
things I've witnessed about it:
In the web UI of SharePoint, if I go to the list properties and drill into
my taxonomy site column I notice it shows that it isn't mapped to a
termset. Keep in mind that if I do the same thing in Site Settings for my
content type it appears correct. I can do the same thing for the web UI
created custom list and everything is fine (editable in the new form and
the field has the termset defined).
If I use powershell to dump out the info for the site column itself it has
a valid termset.
If I use powershell to dump out the info for the field in the VS2012
created list it shows emtpy guid for the SspId, TermSetId, and TextField.
It also shows IsTermSetValid = False.
If I use powershell to dump out the info for the field in the SharePoint
web UI created list it shows the correct guid for the SspId, TermSetId,
and TextField. It also shows IsTermSetValid = True.
Does anyone know why I seem to be having this behavior for the VS 2012
create custom list? Any help is appreciated.

No comments:

Post a Comment