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.


Topics - Colin Coates

Pages: [1]
1
In previous versions of EA, I was able to view the properties of an AcceptEventAction (in an Activity Diagram) and then set the type of Signal it received; this option appears to have either moved or been removed in EA 15.01512.

Has anyone worked out how to do this in the latest version of EA?

2
In previous versions of EA, I was able to view the properties of a SendSignalAction (in an Activity Diagram) and then set the type of Signal it emitted...
This option now appears to have been moved or removed.

Has anyone figured out how to do this in the latest version?

3
Automation Interface, Add-Ins and Tools / AddRow in SearchWindow
« on: October 08, 2019, 11:34:18 pm »
I create a custom SQL search named "Unknown GUID" as follows:
Code: [Select]
select ea_guid as CLASSGUID, object_type as CLASSTYPE from t_object where ea_guid = '';
The query above is deliberately constructed to return zero rows in its result set.

I then have the following PHP code:
Code: [Select]
<?php
$ea 
com_get_active_object('EA.App');
$sw $ea->Repository->SearchWindow;
$ea->Repository->RunModelSearch('Unmatched GUID','','','');
const 
otElement 4;
$sw->AddRow(otElement,'09D94D1D-CB0C-4d61-844E-A41C25E706EF',3,'Signal',0); // this element exists
$sw->EnsureVisible();
$ea NULL;
?>


On running the script (at the command line), I see:
Code: [Select]
<?php
d
:\colin.coates\php>php -f search.php
php 
-f search.php
PHP Fatal error
:  Uncaught com_exceptionError [0x80010105The server threw an exception.
 
in D:\colin.coates\php\search.php:6
Stack trace
:
#0 D:\colin.coates\php\search.php(6): variant->AddRow(4, '09D94D1D-CB0C-4...', 3, 'Signal', 0)
#1 {main}
  
thrown in D:\colin.coates\php\search.php on line 6

I do not know why this is throwing an exception?

4
I have written a PHP script that:
1.   Connects to a running instance of Sparx Enterprise Architect
2.   Opens a CSV file (PHP functionality)
3.   Reads each row of the CSV file
4.   Creates requirement elements depending on the contents of each row
 
Before creating a new requirement element, the script looks for whether a requirement with the same name (id) already exists.
 
The script contains a log message:
echo ($view->Elements->GetByName($id))->Name . "\r\n";
 
On executing the script, I see the many error messages like:
PHP Notice:  Trying to get property 'Name' of non-object in D:\colin.coates\php\visualize-requirements.php on line 43
 
It looks like something is wrong with the creation of new requirement elements in my script:
Code: [Select]
function new_rqmnt($view, $id, $text) : object {
    $rqmnt = null;
    if ($view != null) {
        $rqmnt = $view->Elements->AddNew($id, "SysML1.4::Requirement");
        $rqmnt->Update();
        $taggedValues = $rqmnt->TaggedValues;
        foreach ($taggedValues as $taggedValue) {
            switch ($taggedValue->Name) {
            case "id":
                $taggedValue->Value = $id;
                break;
            case "text":
                // $taggedValue->Value = "<memo>";
                $taggedValue->Notes = $text;
                break;
            default:
                echo "Tag \"$taggedValue-Name\" not found!\r\n";
            }
            $taggedValue->Update();
        }
        $rqmnt->Update();
        echo ($view->Elements->GetByName($id))->Name . "\r\n";
        return $rqmnt;
    } else {
        echo "Null view object?\r\n";
        return null;
    }
}

I am using Sparx Enterprise Architect version 13.5.1352 and PHP version 7.2.1.

Can you suggest what the problem might be?

5
Bugs and Issues / FEAP broken by installing EA 14.0
« on: May 21, 2018, 05:59:41 pm »
Hi all,

I installed EA 14 and started seeing ODBC issues with creating new FEAP (Firebird database Enterprise Architect Project) files, such as error messages on trying to create a new FEAP.

Even after downgrading to EA 13.5, the problems persist. I am seeing error messages like:
Code: [Select]
MICROSOFT OLE DB Provider for ODBC Drivers [-2147467259]
[Microsoft][ODBC Driver Manager]
Data Source name not found and no default driver specified.

I tried copying OdbcFb.dll into the SparxSystems\EA folder inside program files, but this did not fix the problem.

Has anyone else noticed a similar problem and figured out how to solve it, please?

6
General Board / Is there an enumeration of Subtypes?
« on: May 09, 2018, 09:43:59 pm »
Can anyone point me toward documentation that enumerates all possible values of Subtype (corresponding to the Ntype column in t_object repository database table)?

I guess that such a table would ideally contain Object_Type, Ntype and a human readable string for Ntype.

7
General Board / Where is Subtype stored in the repository?
« on: May 09, 2018, 07:53:47 pm »
Subtype is a property of the Element (class) in the Enterprise Architect Object Model. The Sparx Systems documentation states that the t_object table (of the model repository) is associated with the Element (class). However, the t_object table does not contain a Subtype column...

I am wondering where Subtype is stored and suspect it may actually be in some other table. Can anyone suggest where it might be?

8
General Board / Are Virtual Master Documents on their way out?
« on: February 20, 2014, 01:02:55 am »
I've been spending some time with the Sparx Enterprise Architect version 11 Beta, and started to wonder whether Virtual Master Documents might be on their way out?

The "Generate Documentation" dialogue is now replete with drop-down lists to select:
  • Template
  • Table of Contents
  • Stylesheet
  • Cover Page

Since you can now use the dialogue to select TOC, stylesheet and cover page, why would you need a Virtual Master Document? Well, to re-order the presentation of model packages of course!

So far I'm enjoying the difference, since it removes the stuff that was confusing about VMD's and focuses their usefulness on what they do well.  :)

Pages: [1]