Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All
Expand Minimize


Retrieves the list view item currently under the cursor.

int GetHotItem( );

The index of the current hot item of the list view control.

This member function implements the behavior of the Win32 macro, ListView_GetHotItem, as described in the Windows SDK. The hot item is defined as the currently selected item when hot tracking (and hover selection) is enabled.

If hot tracking is enabled, when a user pauses over a list view item, the item label is automatically highlighted without the use of a mouse button.

	// Set the hot item to the first item only if no other item is 
	// highlighted.
	if (m_myListCtrl.GetHotItem() == -1)

Header: afxcmn.h

Community Additions

© 2015 Microsoft