?? 列表框如何知道按了哪列.txt
字號:
list列表框,有多個列,如何在程序中知道按了哪個列的標題
響應LVN_COLUMNCLICK消息
void YourDlg::OnColumnclickClcurveList(NMHDR* pNMHDR, LRESULT* pResult)
{
NM_LISTVIEW* pNMListView = (NM_LISTVIEW*)pNMHDR;
// TODO: Add your control notification handler code here
int iCol=pNMListView->iSubItem;//從0開始計數的列號
iCol+=1;//列號+1
CString strColNO;
strColNO.Format("你單擊了第 %d 列",iCol);
AfxMessageBox(strColNO);
*pResult = 0;
}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -