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 - JuergenA

Pages: [1]
1
Hello,

great tool, EA, but I miss a nice feature to hide
all attributes of a class in a class diagram that
do not belong to a stereotype.

In the dialog "element features" - > "specify feature visibility" -> "hide stereotyped features"
I can specify a list of stereotypes to hide all
attributes with this stereotype.

I miss the "not" operator here.

I am doing ER modelling and mark the primary key
attributes of my entity classes with the stereotype
"pk", all normal attributes do not have a stereotype.

No I want to create a class diagram that shows
all entity classes and the primary key attributes only.

Since the normal attributes have no stereotype,
I cannot hide all attributes but the "pk" attributes.

And I don't like the work-around to create a stereotype
"normal" or something else for the normal attributes
to be able to hide them, since the steretype will be
displayed in the class diagram, but I want only the
"pk" stereotype to be seen, not the "normal" stereotype.

Nevertheless, EA is a great tool!

greetings,

  Juergen


2
Hi,

if I call the method to find an attribute of a class by its name I get the following error code:

  ?err.Number
  -2147221504
  ?err.Description
  Action is not supported

The attribute name and the class does exist, but
?class.IsNew says "true".

Any hint?

thx,
 Juergen

Code:

Dim aAttr As EA.Attribute
Dim aClass As EA.Element
...
sAttrName="existing_attribute_name"
aClass.Attributes.GetByName(sAttrName)
... -> error!

3
Hello,

I create a new class with a new static class attribute via VBA automation.

The code does work but if I put the new class
into a class diagram in EA, the new attribute
is NOT static (underlined), although the "static" checkbox
has is checked in the attribute property dialog of EA.

Is this a bug or have I forgotten a refresh on anything?

thx,
 Juergen


Public Sub test()

   Dim aClass As EA.Element
   Dim aAttr As EA.Attribute
   
   Set aClass = m_Repository.Models.GetAt(0).Packages.GetByName("Logical View") _
       .Packages.GetByName("BO_Model").Packages.GetByName("Enumerations").Elements.AddNew("NewClass", "Class")
   Set aAttr = aClass.Attributes.AddNew("NewAttribute", "Any")
   aAttr.IsStatic = True
   aAttr.Update
   aClass.Attributes.Refresh
   

End Sub


Pages: [1]