Sparx Systems Forum

Enterprise Architect => Automation Interface, Add-Ins and Tools => Topic started by: Stenvang on September 24, 2015, 06:59:20 am

Title: Find hyperlinks located in notes (property dialog)
Post by: Stenvang on September 24, 2015, 06:59:20 am
Hi

I'm writing a c# add-in to Enterprise Architect v. 10 and got stuck on a problem trying to pull out hyperlinks from notes fields (in the property dialog of an element or diagram, not the Note element).

So lets say I wrote the following in the notes field:
"Something something... Wooops a <hyperlink>. And then something something".

The hyperlink could refer to another element without having a connector bound to it. Is it possible to programmatically find this hyperlink?
Title: Re: Find hyperlinks located in notes (property dia
Post by: qwerty on September 24, 2015, 07:39:45 am
The note property of the according Note element will have something like
Code: [Select]
bla <a href="$inet://hyper"><font color="#0000ff"><u>hyper</u></font></a> blabla

q.
Title: Re: Find hyperlinks located in notes (property dia
Post by: ashwinv on October 02, 2015, 01:00:13 am
you could perform a simple regex against the notes field to get all such hyperlinks