error LNK2019: unresolved external symbol _WinMain@16 referenced in function ___tmainCRTStartup

Thats a linker problem.

Try to change Properties -> Linker -> System -> SubSystem (in Visual Studio).

from Windows (/SUBSYSTEM:WINDOWS) to Console (/SUBSYSTEM:CONSOLE)

This one helped me

Leave a Comment