MFC获取文件图标
2012-11-01 09:43 龙成 阅读(1159) 评论(0) 编辑 收藏 举报CString strNotePadPath("D:\\svnfile\\KSRecorder\\KSRecord.sln"); SHFILEINFO stFileInfo; :: SHGetFileInfo( strNotePadPath,0,&stFileInfo,sizeof(stFileInfo),SHGFI_ICON); ::SendMessage(this->m_hWnd,WM_SETICON,ICON_SMALL,(LPARAM)stFileInfo.hIcon);