Hi Rob,
Let's say you've got this in your shape script:
print("#addin:AddInRegKey, MethodName#");
AddInRegKey then has to match the name of the Add-In as listed in the registry under HKCU\Software\Sparx Systems\EAAddins. (I think this is the same as the name shown in the Extensions -- Manage Add-Ins dialog).
In the main class of your Add-In (as specified by the same registry key), you need a method with the following signature:
public string MethodName(Repository repository, string elementGuid, Object args)
First thing in there, if you're passing arguments, is to cast args. If you want to pass more than one argument, cast args to an Object array, then cast each argument in turn. If you're not passing any arguments, you still need the dummy parameter in the method signature.
Please note that doing a lot of Add-In calls in a shape script can have a significant performance impact, especially in a networked environment, so it's a good idea to write the method with an eye to performance.
HTH,
/Uffe