trichview.com

trichview.support




I cannot Import/Export any OLE objects from/to RTF?


Return to index


Author

Message

Zhangzhi

Posted: 04/22/2004 10:50:36


I see Insert ole objetct as  to Richview!

--------------------------------

var oc: TOleContainer;

    created: Boolean;

begin

  oc := TOleContainer.Create(nil);

  oc.Visible := False;

  oc.BorderStyle := bsNone;

  oc.Parent := RichViewEdit1;

  created := True;

  try

    oc.CreateObject( 'Equation.3', False);

  except

    try

      oc.CreateObject( 'Equation.2', False);

    except

      try

        oc.CreateObject( 'Equation', False);

      except

        created := False;

      end;

    end;

  end;

  if not created then begin

    oc.Free;

    exit;

  end;

  oc.SizeMode := smAutoSize;

  oc.OnResize := OnOleResize;

  oc.OnActivate := OnOleActivate;

  oc.OnDeactivate := OnOleDeactivate;

  oc.Visible := True;

  oc.OnMouseUp := OnOleMouseUp;

  RichViewEdit1.InsertControl('', oc,rvvaBaseline);

--------------------------------


but TRichView not save/load the ole object from/to RTF?





Powered by ABC Amber Outlook Express Converter