|
From: John <10...@ic...> - 2001-04-10 05:51:15
|
I am new to C++ programming and following tutorial from www.winprog.org. Every thing in this tutorial worked fine with the exception of two toolbar examples. Source code for one example is from toolbar_one.zip . Resouce file will need absolute path for bmp file name. In both cases I am getting Linker error: f:\codelocal\new folder\newproject\toolbar\toolbar_one.o(.text+0x38f):toolbar_one.c: undefined reference to `InitCommonControls@0' I tried to compile toolbar source code from Dev-C++ example folder ( Dev-C++\Examples\MdiApp ) and got following Compiler error: f:\codelocal\new folder\new folder\mdiunit.c: In function `BOOL LoadFile(HWND__ *, CHAR *)': f:\codelocal\new folder\new folder\mdiunit.c:30: warning: converting NULL to non-pointer type f:\codelocal\new folder\new folder\mdiunit.c: In function `BOOL SaveFile(HWND__ *, CHAR *)': f:\codelocal\new folder\new folder\mdiunit.c:62: warning: converting NULL to non-pointer type f:\codelocal\new folder\new folder\mdiunit.c: In function `int WinMain(HINSTANCE__ *, HINSTANCE__ *, CHAR *, int)': f:\codelocal\new folder\new folder\mdiunit.c:163: warning: converting NULL to non-pointer type Linker error: f:\codelocal\new folder\new folder\mdiunit.o(.text+0x323):mdiunit.c: undefined reference to `InitCommonControls@0' I don't know what I am doing wrong. I tried to use new command InitCommonControlsEx ( MSND ToolBar Using ) but no luck. Also, ICC_BAR_CLASSES which should be defined in commctrl.h (folder Dev-C++\Include\commctrl.h) is not there, all the time it gives the error of undefined. Can some body tell me how to correct the ICC_BAR_CLASSES in file commctrl.h. I already installed twice the Dev-C++ thinking that I might have corrupted some files, but no difference. Jasbir Chauhan |