2016-08-14 99 views
1

這個錯誤真的讓我瘋狂!我如何解決它?Visual Studio生成錯誤「無法解析的外部符號WinMain」

這是我的輸出:

1>------ Build started: Project: GenericProjectName, Configuration: Debug x64 ------ 
1>MSVCRTD.lib(exe_winmain.obj) : error LNK2019: unresolved external symbol WinMain referenced in function "int __cdecl invoke_main(void)" ([email protected]@YAHXZ) 
1>C:\generic\path\to\executable.exe : fatal error LNK1120: 1 unresolved externals 
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ========== 

是的,我有選擇的子系統的Windows。

回答

0

我設法解決它。我查看了一個較舊的項目設置,並選擇了「」(沒有!)作爲子系統。

然後,我改變了這個項目的子系統,並將其更改爲未設置(並且爲了確保也刪除了文本)。

猜猜是什麼?它以某種方式工作!

相關問題