Call add-in method from macro? SOLVED
After being stuck on this for days I hit on a solution.
In my OnConnection event in the Delphi code I put something like:
var
SelfDisp : OleVariant;
begin
SelfDisp := Self as IMyClassDisp;
OleVariant(AddInInst).Object := SelfDisp;
(IMyClassDisp is a descendant of IDispatch).
Then the IMyClassDisp methods included in the type library can be called from a macro using the same syntax I had tried earlier.
Just thought I would post this note in case anyone else finds this thread whilst stuck on the same problem.
|