Sparx Systems Forum
Enterprise Architect => Automation Interface, Add-Ins and Tools => Topic started by: DhoX on March 14, 2011, 10:55:05 pm
-
Hello,
I have a Question about using and creating a MDG Add-In.
I wrote a working AddIn and now i want to exand this AddIn with a function that react on the MDG_PreReverse Event.
So I created a MDG Technology and added all MDG_event Prototypfunctions to my AddIn (Cause in the UserGuide stand i should respond to every MDG_Event).
On the EA_Connect event i return "MDG" so that EA know that it's a MDG_AddIn.
First i only want to pop up a MessageBox when I notice the MDG_PreReverse Event.
In Enterprise Architect under the "Add-In" Menu i now got a new Submenu "Connect External Project", but the external Project is always gray (I can't click or activate it).
Do I miss something?
Or where's the failure?
Best regards
DhoX
-
I'm new to the whole MDG / Add-in thing so may be completely wrong, but have you responded to the EA event to enable the menuitem?
eg:
public void EA_GetMenuState(EA.Repository Repository, string Location, string MenuName, string ItemName, ref bool IsEnabled, ref bool IsChecked)
{
IsEnabled = (ItemName == "Connect External Project");
}
-
Oh, shame on me!
I had never thought of that!
Sometimes the answer is to easy to can be found. :D
Big Thanks for that!
Now I can connect and can respond to Pre and Post Generate Event,
but not to the PreReverse.
I use EA version 7.5.849.
Any known Bugs or Issues with PreReverse and this Version?
Searched in the Versionhistory but found nothing.
-
I haven't coded for any of the MDG events yet, so can't help on those sorry.
Sorry this isn't much help - but can you upgrade to 8.0.864 (latest production) and see if that works? If you're not under support - you might be able to try the trial version and if it works upgrade?