Author Topic: AddNew method does not work anymore in EA 6.5.800  (Read 2508 times)

ablaz

  • EA Novice
  • *
  • Posts: 6
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
AddNew method does not work anymore in EA 6.5.800
« on: November 22, 2006, 09:21:21 am »
EA version: 6.5.800

AddNew method of Automation Interface does not work anymore for nested elements (e.i. Port of the Component):

Example:

EA::Element* component;
.....
component->Elements->AddNew( "port1", "Port" ); // "Invalid parent for Port" exception

«Midnight»

  • EA Guru
  • *****
  • Posts: 5651
  • Karma: +0/-0
  • That nice Mister Grey
    • View Profile
Re: AddNew method does not work anymore in EA 6.5.
« Reply #1 on: November 23, 2006, 04:44:46 am »
Have you reported this directly to Sparx?

The forum is good, but Sparx needs to know about this kind of thing directly.

From the EA main menu choose Help | On-line Resources | Bug Report Page. This will get you to the right spot.

Please let us know what happens, and whether Sparx has a workaround or an expected resolution date.

David
No, you can't have it!

ablaz

  • EA Novice
  • *
  • Posts: 6
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
Re: AddNew method does not work anymore in EA 6.5.
« Reply #2 on: November 24, 2006, 12:40:23 am »
I reported this bug to Sparx Systems and they could reproduce it. It seems that the only workaround for now is downgrading to EA 6.5.799.  ;D

Andrej.

Aaron B

  • EA Administrator
  • EA User
  • *****
  • Posts: 904
  • Karma: +13/-0
    • View Profile
Re: AddNew method does not work anymore in EA 6.5.
« Reply #3 on: November 26, 2006, 02:38:13 pm »
This issue should be fixed in the next build of EA (6.5.801).  If there are any problems after installing 801, please contact us again.

bittercoder

  • EA User
  • **
  • Posts: 30
  • Karma: +0/-0
  • .Net developer
    • View Profile
Re: AddNew method does not work anymore in EA 6.5.
« Reply #4 on: December 12, 2006, 12:32:38 pm »
I'm experiencing a similar problem (intermittent failure when executing Elements.AddNew via C# - it ends up raising a COMException with the message "Internal error" - which causes EA to be shut down..

I can't reliably reproduce it alas - but it seems to be when I execute AddNew in a loop for multiple new elements that it eventually bails out...

Aaron B

  • EA Administrator
  • EA User
  • *****
  • Posts: 904
  • Karma: +13/-0
    • View Profile
Re: AddNew method does not work anymore in EA 6.5.
« Reply #5 on: December 12, 2006, 02:50:18 pm »
bittercoder,
EA 6.5 build 801 should be available very soon.  When it is released, please install and see if it resolves your issue.  If the problem continues, please submit a bug report with details on the issue
http://www.sparxsystems.com.au/support/bug_report.html

bittercoder

  • EA User
  • **
  • Posts: 30
  • Karma: +0/-0
  • .Net developer
    • View Profile
Re: AddNew method does not work anymore in EA 6.5.
« Reply #6 on: December 12, 2006, 03:11:34 pm »
Will do, thanks for the heads up.

ablaz

  • EA Novice
  • *
  • Posts: 6
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
Re: AddNew method does not work anymore in EA 6.5.
« Reply #7 on: December 19, 2006, 04:11:22 am »
Experiencing THE SAME PROBLEM with EA 6.5.801!
Guys, do you test your product releases at all? :)

Paolo F Cantoni

  • EA Guru
  • *****
  • Posts: 6264
  • Karma: +104/-89
  • Inconsistently correct systems DON'T EXIST!
    • View Profile
Re: AddNew method does not work anymore in EA 6.5.
« Reply #8 on: December 19, 2006, 04:16:42 am »
Quote
Experiencing THE SAME PROBLEM with EA 6.5.801!
Guys, do you test your product releases at all? :)
To be fair to Sparx, they haven't claimed it would be completely fixed in build 801 nor was there mention of AddNew in the 801 release notes...

Paolo (not an apologist for Sparx...)
Inconsistently correct systems DON'T EXIST!
... Therefore, aim for consistency; in the expectation of achieving correctness....
-Semantica-
Helsinki Principle Rules!

ablaz

  • EA Novice
  • *
  • Posts: 6
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
Re: AddNew method does not work anymore in EA 6.5.
« Reply #9 on: December 19, 2006, 05:16:55 am »
I thought that this issue is covered by the following statement in the release notes:
"Improved automation interface to allow creation of certain child elements via the automation interface."

Just to clarify the severity of this bug: for those who is extensively using the automation interface of EA for model creation, the new releases with unresolved issue 06110279 are ABSOLUTELY UNUSABLE.

incanus

  • EA User
  • **
  • Posts: 33
  • Karma: +0/-0
    • View Profile
Re: AddNew method does not work anymore in EA 6.5.
« Reply #10 on: March 16, 2007, 06:39:32 am »
Is this fixed?
I'm trying to transform an use case to composite element by creating a children activity diagram, whit its children elements using:
Set myDiagrama = myElement.Diagrams.AddNew("Use Case", "Activity") and
Set acti = myElement.Elements.AddNew(Name, "Activity")
but i get an error, and it doesn't let me create the nested activity diagram at all.
The same Add-in works fine in EA 799,

Example:
- Use case (view)
 - Use case (package)
   - use case diagram (diagram)
   - UseCaseN1 (element)
      - Activity Diagram (diagram)not working.
      - ActivityN1 (element)not working.
i'm using EA 6.5.804
« Last Edit: March 16, 2007, 06:41:34 am by incanus »

ablaz

  • EA Novice
  • *
  • Posts: 6
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
Re: AddNew method does not work anymore in EA 6.5.
« Reply #11 on: March 16, 2007, 06:50:13 am »
I'm afraid it is not. I've been trying to convince Sparx that this bug is not yet fixed since 6.5.801. But their tests pass.   :-/

incanus

  • EA User
  • **
  • Posts: 33
  • Karma: +0/-0
    • View Profile
Re: AddNew method does not work anymore in EA 6.5.
« Reply #12 on: March 16, 2007, 12:36:57 pm »
I'm correcting myself, i can create the diagram using:
Set myDiagrama = myElement.Diagrams.AddNew("Use Case", "Activity")

But i cant create the element using:
Set acti = myElement.Elements.AddNew("SomeState", "StateNode")

Anyone else is having this problem in EA 6.5.804?
Best regards...
« Last Edit: March 16, 2007, 12:50:45 pm by incanus »

KonradMadej

  • EA Novice
  • *
  • Posts: 1
  • Karma: +0/-0
    • View Profile
Re: AddNew method does not work anymore in EA 6.5.
« Reply #13 on: March 16, 2007, 12:48:32 pm »
Yes. In my addin it also causes an exception.
Here is code (C#):

EA.Diagram activity = (EA.Diagram)eauc.Diagrams.AddNew(eauc.Name,"Activity");
activity.ShowDetails = 0;
activity.Update();
eauc.Diagrams.Refresh();
EA.Element initial = (EA.Element)eauc.Elements.AddNew("", "StateNode");

Last line causes an exception. Type of eauc object is UseCase. This code creates a diagram nested in UseCase element, but it cannot create a StateNode element.

I've already sent this piece of code with bug report to Sparx. They've promised to make its priority higher. Probably it can be resolved in one or two builds.

Best regards,
Konrad Madej

« Last Edit: March 16, 2007, 12:50:51 pm by KonradMadej »

ablaz

  • EA Novice
  • *
  • Posts: 6
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
Re: AddNew method does not work anymore in EA 6.5.
« Reply #14 on: April 03, 2007, 12:53:40 am »
Possible solution of the problem: do not set Repository.EnableUIUpdates property to "false" before creating the model in case you do it. That caused the exception in my case.