How to pass HDC within Message?

Post a reply


In an effort to prevent automatic submissions, we require that you complete the following challenge.
Smilies
:D :) ;) :( :o :shock: :? 8-) :lol: :x :P :oops: :cry: :evil: :twisted: :roll: :!: :?: :idea: :| :mrgreen: :geek: :ugeek: :arrow: :angel: :clap: :crazy: :eh: :lolno: :problem: :shh: :shifty: :sick: :silent: :think: :thumbup: :thumbdown: :salute: :wave: :wtf: :yawn: :facepalm: :bravo: :dance: :beard: :morebeard: :xmas: :HeHe: :trollface: :cookie: :rainbow: :monkeysee: :monkeysay: :happybday: :headwall: :offtopic: :superhappy: :terms: :beer:
View more smilies

BBCode is ON
[img] is OFF
[flash] is OFF
[url] is ON
Smilies are ON

Topic review
   

Expand view Topic review: How to pass HDC within Message?

Re: How to pass HDC within Message?

Post by HotKeyIt » 12 May 2014, 08:50

SendMessage(HWindow, WM_PRINTCLIENT, (WPARAM)HDC, 0);

How to pass HDC within Message?

Post by brandonhotkey » 12 May 2014, 08:35

How can I send HDC within message?

Code: Select all

SendMessage(HWindow, WM_PRINTCLIENT, HDC, 0);
prints error cannot convert parameter 3 from 'HDC' to 'WPARAM' (C++)

Or I tryied:

Code: Select all

SendMessage(HCapture, WM_COMMAND, 0, HDc);
and recieved error:
C2664: 'SendMessageW' : cannot convert parameter 4 from 'HDC' to 'LPARAM'
There is no context in which this conversion is possible

Top