Sparx Systems Forum

Enterprise Architect => Automation Interface, Add-Ins and Tools => Topic started by: Monsieur on June 08, 2015, 11:58:35 pm

Title: Free sorting and automation
Post by: Monsieur on June 08, 2015, 11:58:35 pm
Hello Folks,

I am doing some import export work within EA.
Here is my problem:

And i am ripping my hair off. I do not find this free sorting anywhere in the base. Where is it? How to keep free sorting? How to dump a model keeping this treeorder? I thought it was Tpos... but it is not! What is this Tpos?!

I tried scripting this but it only order by ID or name...
Thanks for the help!
Title: Re: Free sorting and automation
Post by: qwerty on June 09, 2015, 01:21:26 am
Depending on the type (package/element) it's tpos or treepos. However, EA has some special voodoo how it arranges elements in the project browser to keep them in groups (of diagrams/packages/elements). I once described that in a thread (very long ago).

q.
Title: Re: Free sorting and automation
Post by: Monsieur on June 09, 2015, 01:26:04 am
Quote
Depending on the type (package/element) it's tpos or treepos. However, EA has some special voodoo how it arranges elements in the project browser to keep them in groups (of diagrams/packages/elements). I once described that in a thread (very long ago).

q.

I am sorry Q, but my Tpos value does not reflect the treeposition order (not at all).
Here is Tpos order in my tree view : 1;2;4;6;3;5;7;8 (wich mean 1st object has Tpos = 1; 2nd object has Tpos = 2; 3rd object has Tpos = 4; and weirdly so on.)
I don't understand why the Tpos does not reflect the TreePostion.
Is that normal?
Is there a way to "reset" the tpos value?

M.
Recovery/Clean does not solve the problem
Title: Re: Free sorting and automation
Post by: qwerty on June 09, 2015, 07:24:38 am
Move one of the elements manually and the TPos should be set "as seen" by EA.

(https://dl.dropboxusercontent.com/u/66691423/pic%202015-06-08%20um%2023.27.54.PNG)

q.
Title: Re: Free sorting and automation
Post by: Monsieur on June 09, 2015, 05:24:21 pm
Quote
Move one of the elements manually and the TPos should be set "as seen" by EA.

(https://dl.dropboxusercontent.com/u/66691423/pic%202015-06-08%20um%2023.27.54.PNG)

q.
--> I can't see the image, if i didn't quoted you i wouldn't even have this link (which i can't consult).


Okay so :

That seem to reset the Tpos in the Database.[/s]

You have to order by type/stereotype AND THEN by Tpos. That is part of the Voodoo magic of EA. So the Tpos will never (or with a lot of luck) reset to 1;2;3;4;5... he will reset in something like : group 1 : 2;4;5 + group2 : 1;3 ...

I still don't understand how does EA choose the order between elements (Diagram first, then requirement, then change, ...). If someone have a clue?

Any idea what could have mixed up the Tpos?