Sparx Systems Forum
Enterprise Architect => General Board => Topic started by: zalbina on October 14, 2012, 09:59:55 pm
-
Hello,
I'm trying to get tagged value from an attribute : currentAttribute.TaggedValues.GetByName("length"), but could not find an appropriate collection to save it. What is the return type of this GetByName?
Thanks.
-
GetByName is not supported for all objects. Check the API doc whether it works at all for attribute tags. If not, you have to write your own GetByName.
q.
-
GetByName returns type Object, which you have to cast to whatever type is in your Collection.
So if you are using it on a collection of AttributeTag then you will have to cast it to that type.
Geert
-
Thanks.