Click here to Skip to main content
16,014,765 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Connection points and different process space Pin
Braulio Dez28-May-02 5:02
Braulio Dez28-May-02 5:02 
GeneralRe: Connection points and different process space Pin
Joao Vaz28-May-02 8:21
Joao Vaz28-May-02 8:21 
QuestionHow do i find out which error IShellFolder::EnumObjects returns? Pin
redeemer27-May-02 23:11
redeemer27-May-02 23:11 
AnswerRe: How do i find out which error IShellFolder::EnumObjects returns? Pin
_Magnus_28-May-02 0:53
_Magnus_28-May-02 0:53 
GeneralRe: How do i find out which error IShellFolder::EnumObjects returns? Pin
redeemer28-May-02 3:01
redeemer28-May-02 3:01 
GeneralRe: How do i find out which error IShellFolder::EnumObjects returns? Pin
_Magnus_28-May-02 5:50
_Magnus_28-May-02 5:50 
GeneralConverting HDC to HBitmap Pin
Adrenalin27-May-02 22:55
Adrenalin27-May-02 22:55 
GeneralRe: Converting HDC to HBitmap Pin
Ernest Laurentin28-May-02 6:06
Ernest Laurentin28-May-02 6:06 
The "hDC" must have the image already? you can use the provide function to do that!
HBITMAP GetBitmapFromDC(HDC hDC, int x, int y, int nWidth, int nHeight, bool bCopyToClipboard /* = false */)
{
	HDC  hMemDC = ::CreateCompatibleDC( hDC );
	HBITMAP hImage = ::CreateCompatibleBitmap( hDC, nWidth, nHeight );
	HBITMAP hOldBitmap = (HBITMAP) ::SelectObject( hMemDC, hImage );

	// Copy DC - Actual image is "hDC"
	::BitBlt(hMemDC, 0, 0, nWidth, nHeight, hDC, x, y, SRCCOPY);

	// Copy Image to Clipboard
	if (bCopyToClipboard)
	{
		::OpenClipboard( AfxGetMainWnd() );
		::EmptyClipboard();
		::SetClipboardData(CF_BITMAP, hImage);
		::CloseClipboard();
	}

	::SelectObject( hOldBitmap);
	::DeleteDC( hMemDC );
	return hImage;
}

Good luck!

"One good thing about getting older, you don't lose the ages you've been!"
GeneralListview control Pin
Adrenalin27-May-02 22:49
Adrenalin27-May-02 22:49 
GeneralRe: Listview control Pin
Prem Kumar27-May-02 23:22
Prem Kumar27-May-02 23:22 
GeneralIncluding MSHTML Pin
rrrado27-May-02 22:53
rrrado27-May-02 22:53 
GeneralRe: Including MSHTML Pin
Rama Krishna Vavilala28-May-02 2:01
Rama Krishna Vavilala28-May-02 2:01 
GeneralRe: Including MSHTML Pin
rrrado28-May-02 3:35
rrrado28-May-02 3:35 
GeneralDrawing rotated WMF Pin
27-May-02 20:57
suss27-May-02 20:57 
GeneralClass wont work unless global Pin
Mikel27-May-02 19:01
Mikel27-May-02 19:01 
GeneralRe: Class wont work unless global Pin
Joaquín M López Muñoz27-May-02 20:01
Joaquín M López Muñoz27-May-02 20:01 
GeneralRe: Class wont work unless global Pin
Michael P Butler27-May-02 23:25
Michael P Butler27-May-02 23:25 
Generalprocess, thread's memory question Pin
zecodela27-May-02 18:06
zecodela27-May-02 18:06 
GeneralRe: process, thread's memory question Pin
Michael Dunn27-May-02 18:29
sitebuilderMichael Dunn27-May-02 18:29 
GeneralRe: process, thread's memory question Pin
Alexandru Savescu27-May-02 21:58
Alexandru Savescu27-May-02 21:58 
GeneralRe: process, thread's memory question Pin
zecodela27-May-02 23:23
zecodela27-May-02 23:23 
GeneralRe: process, thread's memory question Pin
zecodela27-May-02 23:23
zecodela27-May-02 23:23 
GeneralRe: process, thread's memory question Pin
Alexandru Savescu27-May-02 23:47
Alexandru Savescu27-May-02 23:47 
GeneralRe: process, thread's memory question Pin
zecodela28-May-02 3:12
zecodela28-May-02 3:12 
GeneralBest Way to Get Installed DLL Version Pin
John Clump27-May-02 17:53
John Clump27-May-02 17:53 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.