c++ - gdi32.dll not linked to Code::Blocks? -


i can't use getstockobject in program. apperently i'm not linked gdi32.dll. it's in system32 folder don't see why can't access it. i'm using code::blocks. know stupid question don't why it's doing this. help?

first, need ensure windows headers included. make sure code file has line @ top:

#include <windows.h> 

second, need make sure instruct linker link gdi32.dll. windows sdk (which should have come ide) includes lib files facilitate dynamically linking system dlls. check project's properties in ide, , make sure linker referencing gdi32.lib (and user32.lib , kernel32.lib, should there).


Comments

Popular posts from this blog

c# - Operator '==' incompatible with operand types 'Guid' and 'Guid' using DynamicExpression.ParseLambda<T, bool> -