Author Topic: Modify Tags on EA_OnNotifyContextItemModified?  (Read 2855 times)

g.makulik

  • EA User
  • **
  • Posts: 355
  • Karma: +0/-0
    • View Profile
Modify Tags on EA_OnNotifyContextItemModified?
« on: January 08, 2013, 12:05:08 pm »
My C# AddIn implements the EA_OnNotifyContextItemModified broadcast event and checks for changes of particular tagged values. If a value is not consistent, it should be changed to a consistent one (actually boolean tagged value types).
I'm calling the EA.TaggedValue.Update() method after changing the value and the EA.Element.Update() method but the changes have no effects (I'm also calling Repository.RefreshOpenDiagrams and closing/opening the diagram doesn't show changes either).

Any idea, what could be wrong or is necessary to do to change tagged values during this event?


Best regards,
Günther
Using EA9.3, UML2.3, C++, linux, my brain, http://makulik.github.com/sttcl/

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13404
  • Karma: +567/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: Modify Tags on EA_OnNotifyContextItemModified?
« Reply #1 on: January 08, 2013, 06:40:52 pm »
Yes, seems like that should be working.

If I were you I would try to setup some kind of logging on the database to figure out which sql commands EA is exactly sending to the database (and which ones it isn't)

Geert
« Last Edit: January 08, 2013, 06:41:20 pm by Geert.Bellekens »

g.makulik

  • EA User
  • **
  • Posts: 355
  • Karma: +0/-0
    • View Profile
Re: Modify Tags on EA_OnNotifyContextItemModified?
« Reply #2 on: January 09, 2013, 11:36:35 am »
Quote
If I were you I would try to setup some kind of logging on the database to figure out which sql commands EA is exactly sending to the database (and which ones it isn't)

Thanks for your suggestion Geert. Can you tell an easy way to do this for an .eap (MS-Access) database? I'd know how to do for an SQL-Server or MySQL DB but I'd like to avoid the mess setting one of them up for use with EA.

Best regards,
Günther
« Last Edit: January 09, 2013, 11:39:19 am by g.makulik »
Using EA9.3, UML2.3, C++, linux, my brain, http://makulik.github.com/sttcl/

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13404
  • Karma: +567/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: Modify Tags on EA_OnNotifyContextItemModified?
« Reply #3 on: January 09, 2013, 03:16:46 pm »
Quote
Can you tell an easy way to do this for an .eap (MS-Access) database?
No sorry, I have no other suggestion than "try google" :-[

Geert