Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - adepreter

Pages: [1] 2 3 ... 9
1
... when the stereotype is defined in an MDG?

Does anybody know?

Thank you in advance,
Alain

2
Are there any plans to provide URLs that are accessible from outside the repository.

Here is a use case:

User 1
- Right-clicks on a diagram and select (new option) "Copy link to diagram" (just as in OneNote).
- Copy the link in an email.

Robot/daemon
- Create links to diagrams and puts them in emails or on a web site

User 2 (recipient)
- Clicks on a URL

EA
- Starts if was not already running
- Opens the diagram and makes it active


3
Related to history of Changes and fixes for Build 1427. (https://sparxsystems.com/products/ea/history.html)

Still no API to make this synchronization automatic vs manually pushing a button every time?

Can't find any.

4
So we can write console programs or services that access the object model in batch mode
- without having to install EA on the server
- without existing limitations which are due to the fact that EA is a desktop program

5
General Board / Re: Pros and Cons of mixing TOGAF and Archimate?
« on: August 27, 2019, 09:04:20 pm »
Indeed it is the same problem everywhere.
http://www.labnaf.one/ln-content/edu/EDU%2020%20Challenges.pdf

An alternative is having one single language that makes sense i.e.
- that is based on precise systems semantics
http://www.labnaf.one/guidance/index.html?guid=6A67F237-E1E4-41a2-BF3E-F922E1B18FF8

- and that is designed to support the complete process of driving transformations (the TOGAF ADM is a process for driving one single change)
http://www.labnaf.one/guidance/index.html?guid=1FC5C565-4DA7-4e0c-AD58-134E8BEC0CA5

For more information please contact Sparx Europe.

6
The alternative is to delete the list view and regenerate it.

7
When you define an element stereotype, you define notably the
- tagged values
- their grouping
- the default child diagram types.

When you "synchronize stereotype", only the tagged values are updated.
Their grouping and the default child diagram are not updated.

So the "synchronize stereotype" feature does only part of its job.

Cheers,
Alain

8
Thank you very much for trying to resolve this.

However there is only one instance running. It is a command line program that start a single new instance using that line "Process externalEaProcess = Process.Start(repositoryFileInfo.FullName)".

So it cannot get the wrong instance since there is only one.

Thank you anyway,
Alain

9
Hello Eve,

Thank you very much for your quick answer.
I tried to use Repository.LoadAddins (see code below) but that does not make the OnInitializeTechnologies to be called.

To summarize:
- If I just open the repository from the Windows UI, it calls OnInitializeTechnologies properly (it has being doing this for years).
- But when a batch program opens the repository then OnInitializeTechnologies is not called, even when Repository.LoadAddins() is called after opening the repository.

What would you suggest?

------------

if (eaRepo.OpenFile(sFullPath))
{
    eaRepo.LoadAddins();
    return true;
}

10
Dear Eve and Ian,

Indeed as indicated on this link provided by Eve, we can load an MDG from an AddIn, and that is what I am doing.

However, the problem is that the OnInitializeTechnologies is not loaded when EA is started in batch mode.

And that prevents us from generating HTML in batch mode, which is a feature I absolutely need (I might not be the only one).

So if the ImportTechnology was working instead, that would be a viable workaround. So the request from Ian should be considered I think.

As a conclusion the ability to load a custom MDG, including in batch mode, is critical.
We should be able to do this
- either OnInitializeTechnologies
- or using ImportTechnology

Any idea, Eve, when we can have a quick fix with one or the other options?

Cheers,
Alain

11
I need to generate HTML using an MDG loaded from my addin. And this needs to run in batch mode.
But OnInitializeTechnologies is not called when running in batch mode.
It works perfectly well when running in normal/user interface mode.

As a workaround I tried to start another instance and call RunHTMLReport() on that other instance (code below)
But RunHTMLReport() returns an error.

Did anybody encounter the same problem... and found a solution :-) ?

Thank you in advance
Alain

-------------

Process externalEaProcess = Process.Start(repositoryFileInfo.FullName)
object obj = Marshal.GetActiveObject("EA.App");
EA.App app = obj as EA.App;
Repository repo = app.Repository;
repo.GetProjectInterface().RunHTMLReport(...)
externalEaProcess.Kill();



12
If you want to define it in the MDG, isn't simple to create a different diagram type and test the diagram type in the shape script?

13
Here is a resulting diagram in compact view mode (name of the diagram stereotype).
http://www.labnaf.one/guidance/index.html?guid=65903864-3A6F-4e6e-B08F-B2AE10211896

These diagrams are generated automatically following diagram templates that can also include auto legends.
Benefits
- All the diagrams are complete
- Saving a lot of time and money
- All the diagrams have a consistent layout

14
   if (hasproperty("diagram.stereotype", "Compact View"))
   {
      defsize(100,15);
      rectangle(0,0,100,100);
      print("#name#");
   }
   else if (hasproperty("diagram.stereotype", "Undecorated View"))
   {
      defsize(105,20);
      rectangle(0,0,100,100);
      addsubshape("paddingUndecoratedShape","n");
      addsubshape("nameUndecoratedShape","center");
      addsubshape("port","w");
   }
   else
   {
      defsize(90,70);
      rectangle(0,0,100,100);
      addsubshape("padding","n");
      addsubshape("name","center");
   }

15
Dear Sparxters,
After changing diagram types using C# code equivalent to the VB Script below...

I noticed that when I make an EXISTING element composite, the default diagram type defined in the MDG is not applied.
It works only for new elements.

Any idea what is missing in the code below to apply the diagram type changes to existing elements?

----
option explicit
sub MigrateDiagramsStereotype (oldType, oldStereotype, newType, newStereotype)
   Dim sql

   Repository.EnsureOutputVisible "Script"
   Repository.ClearOutput "Script"

   ' SQL SERVER SYNTAX ONLY - Cannot be translated to Access as Cast expression does not work with Access
   sql = "update t_diagram " &_
        "set Diagram_Type = '" + newType + "'" &_
        ", StyleEx = cast(replace(cast(StyleEx as nvarchar(max)), 'MDGDgm=" + oldStereotype + "', 'MDGDgm=" + newStereotype + "') as ntext) " &_
        "where " &_
        "Diagram_Type = '" + oldType + "' AND " &_
        "StyleEx like '%MDGDgm=" + oldStereotype + "%'"
   Repository.Execute (sql)
end sub

sub main
      MigrateDiagramsStereotype "Logical",   "MyDiagramPage::MyDiagramStereoyype", "Logical", ""MyNewDiagramPage::MyNewDiagramStereoype"
end sub

main

Pages: [1] 2 3 ... 9