New Win32 Core api broke?

Igor via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Mon Jan 25 14:57:22 PST 2016


  error LNK2019: unresolved external symbol GetStockObject 
referenced in function _D2Application10createWindowMFPFZvZi (int 
Application.createWindow(void function()*))

and the line of code is

wc.hbrBackground = GetStockObject(WHITE_BRUSH);

I've tried to

import core.sys.windows.wingdi;

But that just got me to this error. When I don't use it, the code 
compiles

I was able to solve this problem by importing gdi32.lib on the 
command line.  Shouldn't the module import the lib like it does 
for the other ones? or does it?


More information about the Digitalmars-d-learn mailing list