WindowProv Error FTW WTF ???

Posts 1–5 of 5 · Page 1 of 1
WindowProv Error FTW WTF ???
hello guys,
recently i was trying to make something but i got error which i cant fix:

Code:
#include <windows.h>
#include <windowsx.h>
#include <tchar.h>

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

int WINAPI WinMain(HINSTANCE hInstance,HINSTANCE hPrevInstance,LPSTR lpCmdLine,int nCmdShow)
{
	HWND hWnd;
	CHAR szAppName[]="WindowClass1"; 
	WNDCLASSEX wc;
	ZeroMemory(&wc, sizeof(WNDCLASSEX));
	wc.cbSize = sizeof(WNDCLASSEX);
    wc.style = CS_HREDRAW | CS_VREDRAW;
    wc.lpfnWndProc = WindowProc;
    wc.hInstance = hInstance;
    wc.hCursor = LoadCursor(NULL, IDC_ARROW);
    wc.hbrBackground = (HBRUSH)COLOR_WINDOW;
    wc.lpszClassName = szAppName;
	RegisterClassEx(&wc);
	return 0;
}
and the error is
Code:
Error	2	error LNK2001: unresolved external symbol "long __stdcall WindowProc(struct HWND__ *,unsigned int,unsigned int,long)" (?WindowProc@@YGJPAUHWND__@@IIJ@Z)	C:\Users\Kaloian\documents\visual studio 2010\Projects\DirectX\DirectX\d3d.obj

Error	3	error LNK1120: 1 unresolved externals	C:\Users\Kaloian\documents\visual studio 2010\Projects\DirectX\Release\DirectX.exe
i use VS ultimate 2010 and win 7 64 bit ... i checked the linkers but i dont know where the error is
Where is your WindowProc? You tried to build simple windows application? Send me your project.
add User32.lib
Quote Originally Posted by pceumel View Post
add User32.lib
both kernel32 and user32 are included
@giniyat101 ok gonna try

---------- Post added at 10:32 AM ---------- Previous post was at 09:45 AM ----------

@Jigsaw, @Austin, @Hero, @DaRk, @BACKD00R Close problem solved
u didnt define WindowProc

lol
Posts 1–5 of 5 · Page 1 of 1
This thread is closed for replies.

Similar Threads

Tags for this Thread

None

Talk with us