| 일 | 월 | 화 | 수 | 목 | 금 | 토 |
|---|---|---|---|---|---|---|
| 1 | 2 | 3 | 4 | |||
| 5 | 6 | 7 | 8 | 9 | 10 | 11 |
| 12 | 13 | 14 | 15 | 16 | 17 | 18 |
| 19 | 20 | 21 | 22 | 23 | 24 | 25 |
| 26 | 27 | 28 | 29 | 30 | 31 |
Tags
- 岡崎律子
- VMware
- Okazaki Ritsuko
- 오카자키 리츠코
- youtube
- 프로그램
- 파이어폭스
- MFC
- USB메모리
- 윈도우즈
- KBS한국어능력시험
- php
- Hirano Aya
- KBS
- 백업
- 옥션
- Firefox
- 마비노기
- 프린터
- 맞춤법
- 자바스크립트
- Microsoft
- gentoo
- 리눅스
- 벤치마크
- 平野綾
- vbscript
- synology
- 한국어
- xml
Archives
- Today
- Total
ARCHIVE ...
리스트 컨트롤(CListCtrl) 본문
구조체
typedef struct _LVITEM {
UINT mask;
int iItem;
int iSubItem;
UINT state;
UINT stateMask;
LPTSTR pszText;
int cchTextMax;
int iImage;
LPARAM lParam;
#if (_WIN32_IE >= 0x0300)
int iIndent;
#endif
#if (_WIN32_WINNT >= 0x501)
int iGroupId;
UINT cColumns; // tile view columns
PUINT puColumns;
#endif
#if (_WIN32_WINNT >= 0x0600)
int* piColFmt;
int iGroup;
#endif
} LVITEM, *LPLVITEM;
메소드
- DWORD CListCtrl::SetExtendedStyle(DWORD dwNewStyle);
스타일
- LVS_ICON
- LVS_SMALLICON
- LVS_LIST
- LVS_REPORT
- LVS_EX_FULLROWSELECT
Version 4.70. When an item is selected, the item and all its subitems are highlighted. This style is available only in conjunction with the LVS_REPORT style. - LVS_EX_GRIDLINES
Version 4.70. Displays gridlines around items and subitems. This style is available only in conjunction with the LVS_REPORT style.
예
CListCtrl* pSamiParamList = (CListCtrl*) GetDlgItem(IDC_LIST_SAMIPARAM);
TCHAR* data[][2] = {
{L"Copyright", L"{Copyright (c) Microsoft Corporation. All rights reserved.}"},
{L"Media", L"{SAMI_Demo.wmv}"},
{L"Metrics", L"{time:ms; duration: 73000;}"},
{L"Spec", L"{MSFT:1.0;}"}
};
pSamiParamList->InsertColumn(0, L"Name", LVCFMT_LEFT, 55);
pSamiParamList->InsertColumn(1, L"Properties", LVCFMT_LEFT, 150);
LV_ITEM item;
item.mask = LVIF_TEXT;
for (int i = 0; i < sizeof(data)/sizeof(data[0]); i++)
{
item.iItem = i;
item.iSubItem = 0;
item.pszText = data[i][0];
pSamiParamList->InsertItem(&item);
pSamiParamList->SetItemText(i, 1, data[i][1]);
}
Reference
Comments