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

Pages: [1] 2 3 4
1
I Will :)

2
Thank You Guys,

I'll try my shape script without native; I'll see how it ends.
Mick

3
Hi, qwerty,

Thank you for sharing your thoughts. Finally, I found the problem; I changed the Win Screen Resolution DPI to 110%.
After changing the resolution to 100%, EA shows the icons OK. 

4
Hi Guys,

I don't understand the EA v16.0.1605 (x64) behavior. I have MDG Profile with the stereotype with an icon (RGB 192,192,129) for the background, but EA shows it as a black square - and I don't know why. Because 2hrs ago, it works perfectly.
I'm going slightly mad. What is causing that? I don't change anything (close EA and re-open EA).

Does anybody know a workaround, please, how prevent that EA behavior?
Thanks

Mick

5
Hi Guys,

I please for help: I have shape scrip Provided interface, and I don't know how to hide
stereotype label, if I changed exposed interface to Required :(

What I'm missing? I looked at "query" books and EA help, but I can't find the answer.

Thaks a lot
Mick

---------------------------------------------------------------------------------------------------------
shape main
{
   fixedAspectRatio = "true";
   
   if(hasproperty("parentedge","top"))
   {   
      DefSize(13,40);
      DrawNativeShape();
   }
   
   if(hasproperty("parentedge","left"))
    {
      DefSize(40,13);
      DrawNativeShape();
   }
   
   if(hasproperty("parentedge","right"))
    {
      DefSize(40,13);
      DrawNativeShape();
   }
   
   if(hasproperty("parentedge","bottom"))
   {
      DefSize(40,13);
      DrawNativeShape();
   }
   
}

shape label
{   
   if(hasproperty("parentedge","top"))
   {
      SetOrigin("N",0,0);
      Print("#name#");
   }
   
   if(hasproperty("parentedge","left"))
   {
      SetOrigin("S",0,0);
      Print("#name#");
   }
   
   if(hasproperty("parentedge","right"))
   {
      SetOrigin("S",0,0);
      Print("#name#");
   }
   
   if(hasproperty("parentedge","bottom"))
   {
      SetOrigin("S",0,0);
      Print("#name#");
   }
   
   if(hasproperty("type", "required"))
   {
      Print("#name#");   
   }
   
   /*
   if(HasProperty("Type","Required"))
   {
      Print("#name#");   
   }
   */
}

6
General Board / Re: EA 16 diagram position in browser
« on: September 02, 2022, 09:31:49 pm »
Oh, thank God - Geert :)

7
General Board / EA 16 diagram position in browser
« on: September 02, 2022, 07:20:25 pm »
Hi guys,

I can't find in the release log when Sparx changed the diagram position in the Browser window.
Till ver. 15.x.xxx the diagram was always first under the parent package, and it was (4 me) better for working with elements in the package.
In EA 16.x.xxx, the diagram is unred the sub-packages.

Is there an option for that?

Thanks,
Mick

8
Automation Interface, Add-Ins and Tools / Re: VBScript get mouse X/Y
« on: April 29, 2022, 07:14:40 pm »
Thank you Guys.

9
Automation Interface, Add-Ins and Tools / VBScript get mouse X/Y
« on: April 29, 2022, 05:00:52 pm »
Hi Guys,

it is possible in EA (VBScript) to get mouse coordinates and use them as position
for adding a new element to the diagram, pls?

Mick

10
General Board / Re: SQL fragment for element with linked document
« on: February 01, 2022, 12:58:43 am »
Thanks a lot, Geert!

I'm afraid that I'm that good at creating virtual documents. I found your page about virtual documents, but I don't understand that :/
Maybe one day :)

So long,
Mick

11
General Board / SQL fragment for element with linked document
« on: January 31, 2022, 11:59:51 pm »
Hi Guys,

I have a BPMN diagram with activities that have a linked document.
So, I created a template with the fragment that sorts the diagram element (order by t_diagramobjects.RectLeft ASC, t_diagramobjects.RectTop DESC)
but I have no clue how "print" under the element it's a linked document?

Thanx for the advice,
Mick

12
Thank You Sunshine,

I'm going to dive in int.

Mick

13
Automation Interface, Add-Ins and Tools / Virtual document from vbscript?
« on: September 08, 2021, 03:12:57 am »
Hi guys,

please help me! I'm a bit "out of order", because I don't understand how works virtual documents.

Is is possible have 3 element on the diagram and print them by element type?

1 Diagram = 1 UseCase, 1, Class (stereotype="webpage"), 1 Class (stereotype="service")

And I have no idea how create template that read the diagram elements, and use 3 deferent templates
by element type, in one document,  document chapter?

Thanks for advice

Mick


14
Thank you, Geert!

Well, it was horrible code, indeed :)
I rewrite it without SQL.

Your code will help me in other ideas, thank you again.

Mick

Sub main
   
   On Error Resume Next
   Err.Clear
   
   Repository.EnsureOutputVisible "Script"
   Repository.ClearOutput "Script"
   
   dim msg, appName
   appName = "A&D VBScript"
   
   if Err.Number <> 0 Then
      Session.Output( "NOK" )
      msg=MsgBox( "Unknown Error.", vbOKOnly  + vbExclamation , appName )
      Exit Sub
   else
      dim currentDiagram as EA.Diagram
      set currentDiagram = Repository.GetCurrentDiagram()
      
      'Selected element type=Component check.
      if currentDiagram.SelectedObjects.Count = 0 then
         msg=MsgBox("Select 'Component' element.", vbOKOnly  + vbExclamation , appName)
         Exit Sub
      else
         for each currentDiagram in currentDiagram.SelectedObjects
         
            dim theElement as EA.Element
            set theElement = Repository.GetElementByID(currentDiagram.ElementID)   
            
            if theElement.Stereotype <> "Component" then
               msg=MsgBox("Select 'Component' element.", vbOKOnly  + vbExclamation , appName)
               Exit Sub
            else
               'Check the element has connector.
               dim con as EA.Element
               set con = theElement.Connectors.GetAt(0)
               
               dim client as EA.Element
               set client = Repository.GetElementByID (con.SupplierID )
               
               if client.Name = "" then
                  msg=MsgBox("The connector is missing.", vbOKOnly  + vbExclamation , appName)
                  Exit Sub
               else
                  'Check connector type = Usage.
                  if con.Type <> "Usage" then
                     msg=MsgBox("The connector type must be a 'Usage.'", vbOKOnly  + vbExclamation , appName)
                     Exit Sub
                  else
                     set theElement = Repository.GetElementByID(client.ElementID)
                     
                     dim theComponent as EA.Element
                     set theComponent = Repository.GetElementByID(currentDiagram.ElementID)
                     
                     dim i
                     dim attributes as EA.Collection
                     set attributes = theElement.EmbeddedElements

                     for i = 0 to attributes.Count - 1
                        dim currentAttribute as EA.Element
                        set currentAttribute = attributes.GetAt( i )
                        
                        'pondelok, 09 augusta 2021, 15:19:32
                        'check service name.
                        dim serviceName
                        serviceName = currentAttribute.name
                        if instr(1,serviceName,"(") <> 0 then
                           serviceName = mid(serviceName, 1, instr(1,serviceName,"(") - 1)
                        else
                           serviceName = serviceName
                        end if
                        'Session.Output("serviceName: " & serviceName)
                        'copy webpage interface to the component element
                        Call AddOperation (currentDiagram.ElementID, serviceName, currentAttribute.Notes)
                     next
                  end if
               end if
            end if
         next
      end if
   end if
End Sub

15
Automation Interface, Add-Ins and Tools / Re: interaction points
« on: August 08, 2021, 01:56:29 am »
Hi Guys,

finally, I can't find where is stored info about ProvidedInterface is visible/or not on the diagram?

What is the secret of the Sprax guys?

I tried:
SELECT       
   t_object.Object_ID, t_object.Name,
   t_diagramobjects.ObjectStyle
FROM           
   t_diagramobjects
   INNER JOIN t_object ON t_diagramobjects.Object_ID = t_object.Object_ID
WHERE
   t_object.object_Type = 'ProvidedInterface'

Thanks a lot.

Mick

Pages: [1] 2 3 4