来源(null)

void CTreeCtrlDlg::InitListCtrl1()
{
	CImageList *pImgList=new CImageList;
	pImgList->Create(IDB_TREE,16,2,RGB(0,0,0));
	m_list1.SetImageList(pImgList,LVSIL_NORMAL);
	m_list1.SetImageList(pImgList,LVSIL_SMALL);

	m_list1.SetExtendedStyle(LVS_EX_FULLROWSELECT);
	m_list1.InsertColumn(0,"id",LVCFMT_LEFT,70);
	m_list1.InsertColumn(1,"Context",LVCFMT_LEFT,70);
	m_list1.InsertColumn(2,"Memo",LVCFMT_LEFT,70);
	m_list1.InsertItem(0,"Item1_1",0);
	m_list1.SetItemText(0,1,"Item1_2");
	m_list1.SetItemText(0,2,"Item1_3");

	m_list1.InsertItem(1,"Item2_1",0);
	m_list1.SetItemText(1,1,"Item2_2");
	m_list1.SetItemText(1,2,"Item2_3");

}


Link: http://www.asm32.net/article_details.aspx?id=85