I'm trying to add tag to a group programmatically without using the SetTags method in Content. Analyzing the TagService does not exist in the API methods for this, only Get methods.
I don't know of any API. All I can think is you could directly use SQL (eg. PetaPoco) to write to the cmsTags table. Though obviously it isn't ideal. But if you wrote it as your own class you could at least swap out the implementation if it's ever added to Umbraco in future.
Create tag programmatically
I'm trying to add tag to a group programmatically without using the SetTags method in Content. Analyzing the TagService does not exist in the API methods for this, only Get methods.
https://our.umbraco.org/apidocs/csharp/api/Umbraco.Core.Services.TagService.html
However by the old API this was possible.
My intention is to add tags to repository without linking to a content.
Is there any way other than legacy code?
I question because soon this code will be removed in the next versions of Umbraco.
tks
Anyone?
I don't know of any API. All I can think is you could directly use SQL (eg. PetaPoco) to write to the
cmsTags
table. Though obviously it isn't ideal. But if you wrote it as your own class you could at least swap out the implementation if it's ever added to Umbraco in future.tks Diplo!
is working on a reply...