n0talentGEEK
n0talentGEEK

Reputation: 163

CodeBlocks undefined reference to WinMain@16

I just started studying C++ using CodeBlocks.

When I started to learn how to make class on .h file, first it always return that I'm missing the .h files, I have linked it on Search Directories.

Then when I compile again, the error change into "undefined reference to WinMain@16". I have already added -lmingw32 to linker option, but still return same error.

So I hope anybody would like to tell me how I can fix the problem. Thank you :)

Upvotes: 3

Views: 8463

Answers (1)

user1232296
user1232296

Reputation: 217

try adding library

libcomdlg32.a

project > build options > linker settings

along with

gdi32 ,user32 ,kernel32 , comctl32

Upvotes: 1

Related Questions