trichview.com

trichview.support




Re: ActiveX


Return to index


Author

Message

Sergey Tkachenko

Posted: 10/16/2002 12:03:07


1) You can implement all actions yourself, like in this demo

http://www.trichview.com/support/files/redit.zip


2) You can still make actions work.

Create a timer with the following event:


procedure TActiveFormX.Timer1Timer(Sender: TObject);

var i: Integer;

begin

  for i := 0 to ComponentCount-1 do

    if Components[i] is TrvAction then

      TrvAction(Components[i]).UpdateTarget(RichViewEdit1);

end;


Create a toolbar, assign actions to toolbuttons, and assign the following

code to their OnClick


procedure TActiveFormX.ToolButton3Click(Sender: TObject);

begin

  if (Sender is TToolButton) and (TToolButton(Sender).Action is TrvAction)

then

    TrvAction(TToolButton(Sender).Action).ExecuteTarget(RichViewEdit1);

end;


>

> I need to use TRichView as an ActiveX (delphi ActiveForm). It is not

possible

> to use Actions in this environment (because there is no Application.Idle

> object to handle the message passing). Do you have any recommendations

about

> how to implement the functionality contained in RichViewActions within the

> ActiveForm?

>

> Many thanks,

>

> Chris





Powered by ABC Amber Outlook Express Converter