CListCtrl::DeleteColumn

Deletes a column from the list view control.

BOOL DeleteColumn(
   int nCol 
);

Parameters

  • nCol
    Index of the column to be deleted.

Return Value

Nonzero if successful; otherwise zero.

Example

int nColumnCount = m_myListCtrl.GetHeaderCtrl()->GetItemCount();

// Delete all of the columns.
for (int i=0; i < nColumnCount; i++)
{
   m_myListCtrl.DeleteColumn(0);
}

Requirements

Header: afxcmn.h

See Also

Concepts

CListCtrl Class

CListCtrl Members

Hierarchy Chart

CListCtrl::InsertColumn

CListCtrl::DeleteAllItems