'Programming/MFC'에 해당되는 글 19건

  1. 2015.02.27 CListCtrl

CListCtrl

Programming/MFC 2015. 2. 27. 14:19 |


<컬럼 추가>

CListCtrl::InsertColumn(int nCol, const LVCOLUMN& pColumn);

CListCtrl::InsertColumn(int nCol, LPCTSTR lpszColumnHeading, int nFormat = LVCFMT_LEFT, int nWidth = -1, int nSubItem = -1);

nCol : 새로운 열의 인덱스

pColumn : Address of an LVCOLUMN structure that contains the attributes of the new column.

lpszColumnHeading : address of a string containing the column's heading.

nFormat : Integer specifying the alignment of the column. It can be one of these values : LVCFMT_LEFT, LVCFMT_RIGHT, or LVCFMT_CENTER.

nWidth : Width of the column, in pixels. If this parameter is -1, the column width is not set.

nSubItem : Index of the subitem associated with the column. If this parameter is -1, no subitem is associated with the column.


ex)

m_List_FileList.InsertColumn(0, _T("File Name"), LVCFMT_LEFT, 100);

m_List_FileList.InsertColumn(1, _T("All Path"), LVCFMT_LEFT, 200);

m_List_FileList.InsertColumn(2, _T("Type"), LVCFMT_LEFT, 85);

m_List_FileList.InsertColumn(3, _T("Size"), LVCFMT_LEFT, 85);

'Programming > MFC' 카테고리의 다른 글

Visual Studio로 생성한 MFC SDI MDI 코드 비교정리  (1) 2014.08.18
CListCtrl Column(Width) 고정  (0) 2014.05.19
Detected memory leaks!  (0) 2014.03.31
CDC::StretchBlt  (0) 2013.12.17
CString  (0) 2013.09.13
Posted by HUEJI
: