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 - jaro-lew

Pages: [1]
1
I have found a way:

package = repository.getPackageByGuid(packageElementTheConnectorPointsTo.ElementGUID);

Both package and package.Element have the same GUIDs

2
I'm trying to find out how to get in code (C#) a Package object connected on the diagram with one element with a connector, for example of type Abstraction.

I've found out that the connector from this object connects to
package.Element.ElementID (not with package.packageID)

And here I cannot get from package.Element (this is not from package.Elements collection) to "containing" package.

ParentId is equal 0, and PackageId gives the ID of parent package of the package I need.


Can you advice me?


3
Suggestions and Requests / Re: 9.0 Customise menus
« on: June 02, 2011, 05:15:52 pm »
I wonder if there is a way to expose commands added in add-ins
to Customize option, to be able to assigne shortcut keys.

4

I work with:  8.0.864. Sorry, I should have started with that info.

5
I'm trying to create scenario steps, but what makes me helpless is that
I cannot set ScenarioStep.Results property.
The update method seems not to transfer it to  the tool.

On the other hand I can set ScenarioStep.Uses property.

Code: [Select]
   EA.ScenarioStep step2 = steps.AddNew("Step2", "1");  // 1 - means Actor
    step2.Results = "R";       //doesn't work
    step2.Uses = "N is used";  //works
                    
    step2.State = "5";         //works

    MessageBox.Show("R? " + step2.Results);  //still correct
    if (!step2.Update())
        MessageBox.Show(mRepository.GetLastError());
    steps.Refresh();

    for (short i1 = 0; i1 < steps.Count; i1++)
    {
        EA.ScenarioStep step3 = (EA.ScenarioStep) steps.GetAt(i1);
        if (step3.Name == "Step2")
        {
            MessageBox.Show("R? " + step3.Results);  // not correct
        }
    }


Pages: [1]