if you are using Visual Studio 6, change your linker settings (Project - Settings - Link tab - Project Options) to /subsystem:windows (it should have had /subsystem:console)
Also, remove the define _CONSOLE in the Preprocessor section of the C/C++ tab.