当前位置: 代码迷 >> VC >> listctrl控件 插入图片有关问题
  详细解决方案

listctrl控件 插入图片有关问题

热度:3640   发布时间:2013-02-25 00:00:00.0
listctrl控件 插入图片问题
我用listctrl控件插入图片,但是为什么没有成功呢?能给个可以运行的代码么,谢谢了!!!!里面有个参数不是用Image   Lists中选择索引就行了么?

------解决方案--------------------------------------------------------
CImageList m_ImageList;
CListCtrl m_list;
m_ImageList.Create(32,32,ILC_COLOR32,10,30);
m_list.SetImageList(&m_ImageList,LVSIL_NORMAL);
int i = m_ImageList.Add(...参数);
m_list.InsertItem(i,strName,i);