Sparx Systems Forum

Enterprise Architect => Automation Interface, Add-Ins and Tools => Topic started by: GrahamK on June 06, 2006, 08:35:55 am

Title: Getting Notes in XML.NET format
Post by: GrahamK on June 06, 2006, 08:35:55 am
Hi,

I'm working on a program that exports data from EA. Our source code uses XML.NET style comments but it seems that EA internally converts the comments to and from its own format.

Is there a way to retrieve the Notes in XML.NET format via the automation interface?

Thanks

-- graham
Title: Re: Getting Notes in XML.NET format
Post by: «Midnight» on June 06, 2006, 10:12:24 am
The short answer is "No." At least not without intervening directly. As long as you are in the API, and as long as you have some means of handling XML in the .Net way, why not just set up an element as you need it and then just read the .Notes() property, which returns a string, into the element body (as a node of whatever type you require)? You go the other way by locating the XML node with the notes text and writing it into the EA property.

Not perfectly what you want, but it should hold you for now; it certainly works for me. There have been numerous suggestions and requests regarding making the Notes property XML or even rtf. To date there don't appear to be any bites.

David