>>499のページと、あと

http://www.wwlnk.com/boheme/delphi/techdoc/dad0030.html

なんか参考にして作ってみた。

ComObjユニットにあるTAutoObjectっていうクラスが、あらかじめIDispatchを実装しているらすぃ。
なので、TAutoObjectと、自分が実装したい機能を持ったインターフェースをくっつけて、
新しいクラスを作ればとりあえずOK?みたいな?

uses にComObjを追加

IExposingObjectsDemo = interface
  function Get_Age: Integer;
  function Get_Name: OleVariant;
  procedure Set_Age(Value: Integer);
  procedure Set_Name(Value: OleVariant);
end;

TExposingObjectsDemo = class(TAutoObject, IExposingObjectsDemo)
  function Get_Age: Integer;
  function Get_Name: OleVariant;
  procedure Set_Age(Value: Integer);
  procedure Set_Name(Value: OleVariant);
end;

続く・・