Reference to the focus item in the list
Member of Book (PRIM_BOOK)
Data Type - PRIM_BOOK.BookItem - Item created when an entry is added to a book control
The FocusItem is the item in the list that will react to keyboard input. There is only ever one focus item and it is usually that last item clicked or accessed via the arrow keys. When the FocusItem is set the list will fire an ItemGotFocus event. If focus moves to another item, an ItemLostFocus will be fired first. These events correspond to the OnItemGotFocus and OnItemLostFocus methods on the Prim_Book.iBookDesign interface. If the FocusItem is deleted, the list will assign focus to an arbitrary item, typically the first. FocusItem and CurrentItem may well be different and it is CurrentItem that updates the field values in the component. Before using FocusItem, it is best practice to ensure that both the CurrentItem and FocusItem are the same. This will ensure that field values are up to date. Lists may not have a focus item, so it is prudent to check before using it.
Testing for a focus item before making it the CurrentItem by using GET_ENTRY.
If (#List.FocusItem *isnot *null) Get_Entry Number(#List.FocusItem.Entry) From_List(#List) Endif
All Component Classes
Febuary 18 V14SP2