954,487 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

Visual C++ Form Project - need to get HDC for drawing bitmaps

Hi all

I am fairly new to C++, and am having problems creating a quick GUI application using the Win32 API. I'd like to use the "windows form project" option in Visual C++ ...which creates windows, textboxes, buttons etc. through a drag & drop interface.

The problem is that I need to able to create a GUI with controls for user input, but also draw bitmaps on a large area of the window. In order to do this, I need to access the handle to the device context of the (automatically created) window.

How do I get the handle to the device context, for my bitmap-drawing functions? And will I get the HDC out of the actual frame, or a specific picture box? ...

Any help would be much appreciated.

apcxpc
Junior Poster in Training
55 posts since Sep 2004
Reputation Points: 10
Solved Threads: 0
 
WolfPack
Postaholic
Moderator
2,051 posts since Jun 2005
Reputation Points: 572
Solved Threads: 115
 

This article has been dead for over three months

Post: Markdown Syntax: Formatting Help
You