开发者

Win32 WndProc Name: why can't I change its name?

I have compiled a simple win32 app successfully with bc++ (2 lines excerpt only):

LRESULT 开发者_Go百科CALLBACK WindowProcedure (HWND, UINT, WPARAM, LPARAM);

wincl.lpfnWndProc = WindowProcedure;     

Why can't I rename WindowProcedure and compile this:

LRESULT CALLBACK WndProc (HWND, UINT, WPARAM, LPARAM);

wincl.lpfnWndProc = WndProc;

as error message gives:

Turbo Incremental Link 5.00 Copyright (c) 1997, 2000 Borland Error: Unresolved external 'stdcall WndProc(HWND *, unsigned int, unsigned int, long)' referenced from C:\PROGRAMMING\SALLY\WIN32TUTORIAL\MAIN.OBJ


This is a linker error, not a compiler error. It looks like you have renamed the declaration but not the definition. You need to rename the definition (the part that includes the {body of the function}).

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜