首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 开发语言 > C++ >

一个图标有关问题

2012-02-15 
一个图标问题?DrawlconEx这个函数总是错误为什么呀,错误是没有定义这是为什么呀?error:E:\zhang\shuai\shu

一个图标问题?
DrawlconEx这个函数总是错误为什么呀,错误是没有定义   这是为什么呀?
error:   E:\zhang\shuai\shuai.cpp(39)   :   error   C2065:   'DrawlconEx '   :   undeclared   identifier  


#include   "stdafx.h "  
#include <shellapi.h>  
#include <winuser.h>  
//#include <usser32.lib>  
//using   namespace   std;  
int   APIENTRY   WinMain(HINSTANCE   hInstance,  
HINSTANCE   hPrevInstance,  
LPSTR   lpCmdLine,  
int   nCmdShow)  
{  
//   TODO:   Place   code   here.  

HICON   hIcon;  
HDC   hDC;  
HWND   hWnd;  
HINSTANCE   hInst;  
hDC=GetDC(hWnd);  
hIcon=ExtractIcon(hInst, "C:\\Windows\\System\\Shell32.DLL ",1);  
DrawIcon(hDC,0,0,hIcon);  
DrawlconEx(hDC,0,0,hIcon,NULL,DI_NORMAL);  
//   DrawlconEx();  
return   0;  
}


[解决办法]
winuser.h

Public Declare Function DrawIconEx Lib "user32 " Alias "DrawIconEx " (ByVal hdc As Long, ByVal xLeft As Long, ByVal yTop As Long, ByVal hIcon As Long, ByVal cxWidth As Long, ByVal cyWidth As Long, ByVal istepIfAniCur As Long, ByVal hbrFlickerFreeDraw As Long, ByVal diFlags As Long) As Long

l-> I

热点排行