Sparx Systems Forum
Enterprise Architect => Automation Interface, Add-Ins and Tools => Topic started by: sravang on November 15, 2021, 10:08:15 pm
-
Hello,
I have different types of tags to be added. I am using following code to add them in c#.
EA.TaggedValue customAttributeTag = ele.TaggedValues.AddNew(attribute,GetPropertyType(shape,attribute,out attributeValue,""));
customAttributeTag.Value = attributeValue;
customAttributeTag.Update();
GetPropertyType returns type of tags ex: String,Integer,Float,Date etc.
In the above case it is working fine for String but in case of Integer it is throwing error of cannot convert int to string.
Any Idea about this?
Thanks,
Sravan
-
Technically, the value of a tagged value is always a string.
In some cases EA will add a constraint in the GUI only to select only true/false, or integer or...
Geert