trichview.com

trichview.support




Re: Exceptions handling


Return to index


Author

Message

Sergey Tkachenko

Posted: 09/18/2002 21:34:22


if not aRichView.LoadRTF(afilename) then

  showmessage('error');

aRichView.Format;



>

> Hi,

>

> I've just started with the RichView and I have

> first question.

>

> I have a code:

>

> try

>     aRichView.LoadRTF(afilename);

>     aRichView.Format;

> except

>     showmessage('error');

> end;

>

> and even if there is some exception the try..except

> block doesn't handle it. It seems that the RichView

> takes all the exceptions. So how can I handle this ?

> An easy way to check this is to open a RTF file

> in MS Word and then try to open it in a demo app

> which uses the above code. The MS Word blocks

> the opened file and there is some exception in

> the Delphi IDE (OpenError) but the try..except block

> does not handle it. Of course, the RichView is empty

> after the unhandled exception.

>

> I use the latest beta code and Delphi 6 PRO UP1.

>

> Regards,

> Rafal

>

>





Powered by ABC Amber Outlook Express Converter