Sparx Systems Forum
Enterprise Architect => Automation Interface, Add-Ins and Tools => Topic started by: Danor on March 28, 2013, 03:02:52 am
-
Hello,
I'm working with EA 9.3 and would like to create a Add-In based on Perl. With perlctrl (I've got the PerlDevKit) I'm able to create a .dll out of my perl code.
Up to now I've created a file which contains a EA_Connect function and created me a .dll file. Registered it and added an entry in the EA egistry, so that EA finds it. Unfortunately EA won't start up anymore, unless I delete the registry entry again. Any idea what I could have done wrong ?
Looking forward for some help :) Thanks
the EA_Connect function :
sub EA_Connect {
my $repo = $_[0];
return "";
}
the method declaration for perlctrl:
...
EA_Connect => {
RetType => VT_BSTR,
TotalParams => 3,
NumOptionalParams => 3,
ParamList =>[ ParamName1 => VT_DISPATCH,
ParamName2 => VT_BSTR,
ParamName3 => VT_BSTR],
},
...
the perctrl call :
perctrl myadd.pl
what creates a myadd.dll . Maybe I've missed some important settings ?
-
I'm no perl expert, but have a look at this thread: http://www.sparxsystems.com/cgi-bin/yabb/YaBB.cgi?num=1364378966. Honestly though perl and java are very different, I doubt you'll get this working.
Best regards,
Günther
-
I have uploaded a complete Perl framework you may use: http://community.sparxsystems.com/resources/scripts/extending-ea-perl
q.
-
Thanks for the replies.
I got your perl plugin. I first added the dll file which comes with it, what worked without problems.
Second I created a new dll out of the EaControl, after registering this I have the old Problem ? Do you have an idea what I could have done wrong ?
-
Not really. You need to put in lots of print statements (write to a file) in order to find out where the bug is buried.
q.