property Items.IsItemLocked (Item as HITEM) as Boolean
Returns a value that indicates whether the item is locked or unlocked. /*not supported in the lite version*/

TypeDescription
Item as HITEM A long expression that indicates the handle of the item.
Boolean A boolean expression that indicates whether the item is locked or unlocked.
Use the IsItemLocked property to check whether an item is locked or unlocked. A locked item is always displayed on the top or bottom side of the control no matter if the control's list is scrolled up or down. Use the LockedItemCount property to add or remove items fixed/locked to the top or bottom side of the control. Use the LockedItem property to access a locked item by its position. Use the ShowLockedItems property to show or hide the locked items.

The following VB sample prints the locked item from the cursor:

Private Sub ComboBox1_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
    On Error Resume Next
    ' Converts the container coordinates to client coordinates
    X = X / Screen.TwipsPerPixelX
    Y = Y / Screen.TwipsPerPixelY
    Dim h As HITEM
    Dim c As Long
    Dim hit As EXCOMBOBOXLibCtl.HitTestInfoEnum
    ' Gets the item from (X,Y)
    With ComboBox1
        h = .ItemFromPoint(X, Y, c, hit)
        If Not (h = 0) Then
            If (.Items.IsItemLocked(h)) Then
                Debug.Print .Items.CellCaption(h, c)
            End If
        End If
    End With
End Sub

The following C++ sample prints the locked item from the cursor:

#include "Items.h"
void OnMouseMoveComboBox1(short Button, short Shift, long X, long Y) 
{
	long c = 0, hit = 0, hItem = m_combobox.GetItemFromPoint( X, Y, &c, &hit );
	if ( hItem != 0 )
	{
		CItems items = m_combobox.GetItems();
		if ( items.GetIsItemLocked( hItem ) )
		{
			COleVariant vtItem( hItem ), vtColumn( c );
			CString strCaption = V2S( &items.GetCellCaption( vtItem, vtColumn ) ), strOutput;
			strOutput.Format( "Cell: '%s', Hit = %08X\n", strCaption, hit );
			OutputDebugString( strOutput );
		}
	}
}

The following VB.NET sample prints the locked item from the cursor:

Private Sub AxComboBox1_MouseMoveEvent(ByVal sender As Object, ByVal e As AxEXCOMBOBOXLib._IComboBoxEvents_MouseMoveEvent) Handles AxComboBox1.MouseMoveEvent
    With AxComboBox1
        Dim i As Integer, c As Integer, hit As EXCOMBOBOXLib.HitTestInfoEnum
        i = .get_ItemFromPoint(e.x, e.y, c, hit)
        If Not (i = 0) Then
            With .Items
                If (.IsItemLocked(i)) Then
                    Debug.WriteLine("Cell: " & .CellCaption(i, c) & " Hit: " & hit.ToString())
                End If
            End With
        End If
    End With
End Sub

The following C# sample prints the locked item from the cursor:

private void axComboBox1_MouseMoveEvent(object sender, AxEXCOMBOBOXLib._IComboBoxEvents_MouseMoveEvent e)
{
	int c = 0;
	EXCOMBOBOXLib.HitTestInfoEnum hit;
	int i = axComboBox1.get_ItemFromPoint(e.x, e.y, out c, out hit);
	if (i != 0)
		if ( axComboBox1.Items.get_IsItemLocked( i ) )
		{
			object cap = axComboBox1.Items.get_CellCaption(i, c);
			string s = cap != null ? cap.ToString() : "";
			s = "Cell: " + s + ", Hit: " + hit.ToString();
			System.Diagnostics.Debug.WriteLine(s);
		}
}

The following VFP sample prints the locked item from the cursor:

*** ActiveX Control Event ***
LPARAMETERS button, shift, x, y

local c, hit
c = 0
hit = 0
with thisform.ComboBox1
	.Items.DefaultItem = .ItemFromPoint( x, y, @c, @hit )
	with .Items
		if ( .DefaultItem <> 0 )
			if ( .IsItemLocked( 0 ) )
				wait window nowait .CellCaption( 0, c ) + " " + Str( hit )
			endif
		endif
	endwith
endwith