trichview.support
GetCurrentItemEx List Index out of bounds |
Author |
Message |
Jonas Bilinkevicius |
Posted: 02/03/2004 17:14:42 When i try to create new document (Action New) this code gives the error "List Index out of bounds (-1)". The error appears in the line: vEditor.GetCurrentItemEx(TRVTableItemInfo, rve, item) I think the error appears because of parameter item as in new document there aren't any items. I think it is needed to check if there are any objects in a document before using GetCurrentItemEx procedure. How to do that? procedure.....rvEditCaretMove(Sender: TObject); var item: TCustomRVItemInfo; table: TRVTableItemInfo; rve: TCustomRichViewEdit; begin if not vEditor.CanChange or not vEditor.GetCurrentItemEx(TRVTableItemInfo, rve, item) then exit; table := TRVTableItemInfo(item); ItemNo := rve.GetItemNo(table); |
Powered by ABC Amber Outlook Express Converter