ne0_
September 16th, 2007, 06:58 AM
hi all... i am using ICC_BAR_CLASSES to initialize controls to create toolbar....
but i am getting one error
[linker error] undefined reference to `InitCommonControlsEx@4'
code creating problem is...
//-----------------------------------
INITCOMMONCONTROLSEX InitCtrlEx;
InitCtrlEx.dwSize = sizeof(INITCOMMONCONTROLSEX);
InitCtrlEx.dwICC = ICC_BAR_CLASSES;
InitCommonControlsEx(&InitCtrlEx);
//-----------------------------------
As structure INITCOMMONCONTROLSEX and function InitCommonControlsEx(..) are defined in commctrl.h i included this in my program.....earlier INITCOMMONCONTROLSEX this was also giving same error then i opened the header file commctrl.h and there i found these lines
//--------------------------------------
#if (_WIN32_IE >= 0x0300)
typedef struct tagINITCOMMONCONTROLSEX {
DWORD dwSize;
DWORD dwICC;
} INITCOMMONCONTROLSEX,*LPINITCOMMONCONTROLSEX;
#endif
//--------------------------------------
#if (_WIN32_IE >= 0x0300)
BOOL WINAPI InitCommonControlsEx(LPINITCOMMONCONTROLSEX);
#endif
//--------------------------------------
so in my program before header file in included
#ifdef _WIN32_IE
#undef
#endif
#define _WIN32_IE 0x501
and also
#ifdef _WIN32_WINNT
#undef
#endif
#define _WIN32_WINNT 0x501
now INITCOMMONCONTROLSEX is working fine... but i am getting error with InitCommonControlsEx(...)
error is
[linker error] undefined reference to `InitCommonControlsEx@4'
i am using Dev-C++ 4.9.9.2 compiler
can someone suggest me something...
thanx in advance....
but i am getting one error
[linker error] undefined reference to `InitCommonControlsEx@4'
code creating problem is...
//-----------------------------------
INITCOMMONCONTROLSEX InitCtrlEx;
InitCtrlEx.dwSize = sizeof(INITCOMMONCONTROLSEX);
InitCtrlEx.dwICC = ICC_BAR_CLASSES;
InitCommonControlsEx(&InitCtrlEx);
//-----------------------------------
As structure INITCOMMONCONTROLSEX and function InitCommonControlsEx(..) are defined in commctrl.h i included this in my program.....earlier INITCOMMONCONTROLSEX this was also giving same error then i opened the header file commctrl.h and there i found these lines
//--------------------------------------
#if (_WIN32_IE >= 0x0300)
typedef struct tagINITCOMMONCONTROLSEX {
DWORD dwSize;
DWORD dwICC;
} INITCOMMONCONTROLSEX,*LPINITCOMMONCONTROLSEX;
#endif
//--------------------------------------
#if (_WIN32_IE >= 0x0300)
BOOL WINAPI InitCommonControlsEx(LPINITCOMMONCONTROLSEX);
#endif
//--------------------------------------
so in my program before header file in included
#ifdef _WIN32_IE
#undef
#endif
#define _WIN32_IE 0x501
and also
#ifdef _WIN32_WINNT
#undef
#endif
#define _WIN32_WINNT 0x501
now INITCOMMONCONTROLSEX is working fine... but i am getting error with InitCommonControlsEx(...)
error is
[linker error] undefined reference to `InitCommonControlsEx@4'
i am using Dev-C++ 4.9.9.2 compiler
can someone suggest me something...
thanx in advance....