Jump to content
  • Advertisement
Sign in to follow this  

[Linker error] undefined reference to GetStockObject@4'

This topic is 4165 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I think this is the right place to put this... I'm new to the windows coding scene, and I honestly don't know why this isn't working. To confuse me further, I have another example (written by someone else) that worked... and now it doesnt. Here's where the problem is, what am I doing wrong? (I'm using Dev C++)
      ZeroMemory(&wc, sizeof(WNDCLASSEX));
      wc.style=CS_HREDRAW | CS_VREDRAW | CS_OWNDC;
      wc.hIcon= LoadIcon(NULL, IDI_APPLICATION);       
      wc.hIconSm=LoadIcon(NULL, IDI_APPLICATION); 
      wc.hCursor=LoadCursor(NULL, IDC_ARROW);            

As you can see, I'm just making a window... As of right now, this isn't my code, I'm attempting to get myself set up to that I can actually run this stuff, I got this from the example here: http://www.thehavok.scene.org/scene/32bits/tutorials/directx/thebasics/source/win32creation.html Which is where you can see the code I'm using in its entirety. I'm getting an error on the GetStockObject(GRAY_BRUSH); Thanks for any help.

Share this post

Link to post
Share on other sites
Sign in to follow this  

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!