Tag Info

Hot answers tagged

8

You have to use NavigationTerm To Create Term set: NavigationTerm term2 = navTermSet.CreateTerm("Term 2", NavigationLinkType.FriendlyUrl, term2Guid); /// Verify that the NavigationTermSetView is being applied correctly. Assert.AreEqual(web.ServerRelativeUrl + "/term-2", term2.GetResolvedDisplayUrl(null).ToString()); In order to ...


5

There is no tool for this in the UI. It is pretty straightforward using the object model. I have seen code samples in C# that could be adapted to PowerShell. Alternatively you could try downloading the termset import/export tool from Codeplex.


5

This is how you do it TaxonomyFieldValueCollection tfvc = (list.Items[0]["Field Name"] as TaxonomyFieldValueCollection); var valuesList = (from v in tfvc select v.Label).ToList();


5

@Ashish Patel answer does not actually work when i tried but i was able to figure it out a bit differently. Here is my version of the helper method based on example provided by code ninja blog, here: private List<Guid> GetTermsIds(SPListItem listItem, string fieldName) { var taxonomyField = listItem.Fields.GetFieldByInternalName(fieldName) as ...


5

You cannot completely match the broad feature set of Managed Metadata but you can accomplish a subset of it using the techniques that existed before Managed Metadata was introduced: Define Taxonomic Metadata – Create custom site lists to be used for the management of metadata attributes you want to surface as controlled vocabularies for your site users. ...


5

It is possible to accomplish with OOTB Metadata Navigation and Filtering Feature using Navigation hierarchies control. Navigation hierarchies control allows to select an item in a hierarchy for a managed metadata column with filter for single Term Term with descendant child terms Applying filter in Navigation hierarchies control corresponds to ...


4

You can define a column in a list of type 'Managed Metadata'. This column allows you to set a specific Term Set to use in this column. The TagCloud will not look at this field. Unfortunately it only uses 'I like it' and the tags on the pages (social tagging). As far as I know you have to build your own (or maybe someone did already).


4

In your example you are setting the value of the field, then overwriting it when your loop gets to the next keyword. Rather than calling managedField.SetFieldValue every time you should be collecting all your terms in some form of collection, then calling it with this overload : TaxonomyField.SetFieldValue for example var terms = new ...


4

The advantage of multiple managed paths is it's a first piece of metadata you can have in your farm. It helps break sites out into logical trees even thought they all reside in the same farm. This becomes very beneficial if you organize your structure very flat (many site collection) Based on the managed paths, you can have different SLAs for things ...


4

The solution provided by Vadim above didn't work for me, although it did help me towards an answer. I achieved this in two parts - Via jQuery / DOM get the editable DIV (the one with ID = ContainerId + 'editableRegion') and set the text value of the term you want (note, I didn't find it necessary to set the GUID of the term as well, so just "Africa" in ...


4

Every time you use expensive operation to get data on public site, you should definitely go for caching. There is no difference between query to DB or using term store in Sharepoint. If you feel this operation is called often (each page load) and is expensive you should cache. There is quite a big chance that terms will not be changed very often, so you ...


4

You should check more carefully what you are doing in the code. For example in the line TaxonomyField taxField = (TaxonomyField)item["Dept"]; you are trying to cast TaxonomyFieldValue object to TaxonomyField, which is incorrect, so you get ArgumentNullException on the next line because taxField becomes null. And you are resetting item field value for ...


3

The other option, if you've got the field, and the Term is to use the SetFieldValue method and it's overrides, Specifically SetFieldValue(SPListItem, Term). This will handle all the messy WssId details for you, but it assumes you've got the Term already (or Collection of Terms).


3

Another way to set metadata field value to null.You should get TaxonomyField first. TaxonomyFieldValue fieldValue = new TaxonomyFieldValue(field); field.SetFieldValue(item,fieldValue); Item.UpdateOverwriteVersion();


3

I could be wrong but I believe it's something to do with delegation of administration and user permissions- you can apply security restrictions to groups, and each group can have "groups of terms", aka Term Sets.


3

My Managed Metadata Application Proxy was not a part of the default proxy group. After running the following command $session.TermStores.Count now returns 1! Yay! Set-SPMetadataServiceApplicationProxy -Identity "Metadata Service Application Proxy" -DefaultProxyGroup


3

If you create your own ManagedProperty, e.g. 'Terms' and map it to the crawled property 'ows_taxId_MetadataAllTagsInfo', then you can use in your FullTextSqlQuery a condition like: Terms = '#0[TERM GUID]' For the ManagedProperty make sure you check 'Has Multiple Values' and 'Include values from all crawled properties mapped'. See also on MSDN Querying ...


3

Take a look at MatchPoint for SharePoint (where I am working for). It comes with it's own metadata management, but also supports the ootb taxomomy stuff.


3

To set a taxonomy field you should use TaxonomyFieldValue or TaxonomiFieldValueCollection You first need to find the term in your term store: TaxonomyField taxonomyField = item.Fields[field] as TaxonomyField; TaxonomyFieldValue taxValues = new TaxonomyFieldValue(taxonomyField); TaxonomySession session = new ...


3

If I understood the scenario correctly, you have TERM SET called Department that contains TERMS like IT, Economy. In this case you could create new term inside the term set "Department", and name it "SUPPORT". Then you should merge the IT term to the new "SUPPORT" term. Note! This will remove term IT, so you can no longer use IT when you create new ...


3

Taxonomy is structured and controlled. Folksonomy (Enterprise Keywords) is unstructured and open. A file may be classified with the business taxonomy. The individual user may still want to apply keyword tags that have a special meaning to that individual user and help them find the content they need. There are also techniques and tools to review the ...


3

Term store (database) is identified by you managed metadata service, and you choose the name of your service upon creation in Central Admin. I have my own descriptive name in my development environment: You can also see the name in Central Administration > Manage service applications (in Application management section) > Highlight Managed Metadata Servie ...


3

change your code to: <Taxonomy:TaxonomyWebTaggingControl runat="server" ID="taxProjectOwnerDepartment" Visible="true" IsMulti="false" IsDisplayPickerButton="true"> </Taxonomy:TaxonomyWebTaggingControl> <asp:CustomValidator ID="rfvProjectOwnerDepartment" runat="server" OnServerValidate="validator_ServerValidate" /> now in your ...


3

This method getTermSetsByName returns a collection of termsets, not a single termset, so you should probably do something like: var clientContext = new SP.ClientContext.get_current(); var tSession = SP.Taxonomy.TaxonomySession.getTaxonomySession(clientContext); var ts = tSession.getDefaultSiteCollectionTermStore(); var tset = ...


2

You can create custom field types that use picker controls or use OOTB BDC fields (also a picker control) to search for data. I would warn you against creating custom new/edit form pages. It can be done but its a pain in the... to get working.


2

Rather than indicating where the documents should be displayed, create columns for the document that indicate what the documents are (Content Types) or about (metadata). Then your pages can display things based on the characteristics of the document rather than where someone thought the document should go. This is a better answer for many, many reasons, ...


2

Mmm - I just found this TermSet.GetAllTerms Method If you work for Microsoft and implemented this method - I love you!


2

There is a new method in the 2010 SP1 API: Microsoft.SharePoint.Taxonomy.TermStore.GetSiteCollectionGroup(SPSite currentSite) you can use like this source code: session = new TaxonomySession(site); //Retrieve all Term stores from site collection termstores = session.TermStores; ...


2

Did you try the static method TaxonomyField.GetWssIdsOfTerm()? int[] wssIds = TaxonomyField.GetWssIdsOfTerm(<site>, <termStoreId>, <termSetId>,< termId>, false, 1); Check Peter Hoplars blog post on the subject.


2

The account you are running powershell may not have permission - you will notice that the session lists the service as offline. Check the Administrators for Metadata Service Application and also check Connection Permissions for Metadata Service Application (which is what fixed it for me).



Only top voted, non community-wiki answers of a minimum length are eligible