trichview.com

trichview.support




Re: GetCurrentItemEx List Index out of bounds


Return to index


Author

Message

shmp

Posted: 02/05/2004 1:21:17


I had a similar problem. What I did was to create a boolean say "skipmove"

and set to false. Just before clear, set the boolean to true. After format

then

set the boolean to false again. This will solve your problem.


>

> How to avoid this? Maybe I should move the code into other event?

>

>

> procedure.....rvEditCaretMove(Sender: TObject);

> var

>   item: TCustomRVItemInfo;

>   table: TRVTableItemInfo;

>   rve: TCustomRichViewEdit;

> begin


   if skipmove then Exit;  // ADD THE TRAP EVENT HERE.


>   if not vEditor.CanChange or  not

> vEditor.GetCurrentItemEx(TRVTableItemInfo, rve, item) then

>     exit;

>   table := TRVTableItemInfo(item);

>   ItemNo := rve.GetItemNo(table);

>

> //Reading table properties

>


Regards.

Henry.





Powered by ABC Amber Outlook Express Converter