flamewavetech
Jan 10th, 2002, 07:47 PM
i found a tutorial and it gave me this code
#include <windows.h>
#include <tchar.h>
#include "resource.h"
BOOL MainDialogProc(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
{
return FALSE;
}
int _tmain(void)
{
DialogBoxParam(GetModuleHandle(NULL), MAKEINTRESOURCE(IDD_DIALOG1),
NULL, (DLGPROC)MainDialogProc, 0);
return 0;
}
im using VC++ compiler so i went to insert and made a new dialog and saved it. i then compiled it and got the following errors:
--------------------Configuration: test GUI4 - Win32 Debug--------------------
Compiling...
source.cpp
Linking...
LIBCD.lib(wincrt0.obj) : error LNK2001: unresolved external symbol _WinMain@16
Debug/test GUI4.exe : fatal error LNK1120: 1 unresolved externals
Error executing link.exe.
test GUI4.exe - 2 error(s), 0 warning(s)
So can someone please tell me why it isnt working?
#include <windows.h>
#include <tchar.h>
#include "resource.h"
BOOL MainDialogProc(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
{
return FALSE;
}
int _tmain(void)
{
DialogBoxParam(GetModuleHandle(NULL), MAKEINTRESOURCE(IDD_DIALOG1),
NULL, (DLGPROC)MainDialogProc, 0);
return 0;
}
im using VC++ compiler so i went to insert and made a new dialog and saved it. i then compiled it and got the following errors:
--------------------Configuration: test GUI4 - Win32 Debug--------------------
Compiling...
source.cpp
Linking...
LIBCD.lib(wincrt0.obj) : error LNK2001: unresolved external symbol _WinMain@16
Debug/test GUI4.exe : fatal error LNK1120: 1 unresolved externals
Error executing link.exe.
test GUI4.exe - 2 error(s), 0 warning(s)
So can someone please tell me why it isnt working?