Click here to Skip to main content
16,011,508 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: attach an icon to mouse cursor Pin
vikas choudhry7-Dec-08 23:59
vikas choudhry7-Dec-08 23:59 
GeneralRe: attach an icon to mouse cursor Pin
Hamid_RT8-Dec-08 2:25
Hamid_RT8-Dec-08 2:25 
GeneralRe: attach an icon to mouse cursor Pin
vikas choudhry8-Dec-08 17:18
vikas choudhry8-Dec-08 17:18 
GeneralRe: attach an icon to mouse cursor Pin
vikas choudhry9-Dec-08 1:32
vikas choudhry9-Dec-08 1:32 
GeneralRe: attach an icon to mouse cursor Pin
Hamid_RT9-Dec-08 7:28
Hamid_RT9-Dec-08 7:28 
GeneralRe: attach an icon to mouse cursor Pin
Hamid_RT9-Dec-08 7:28
Hamid_RT9-Dec-08 7:28 
GeneralRe: attach an icon to mouse cursor Pin
vikas choudhry9-Dec-08 17:12
vikas choudhry9-Dec-08 17:12 
GeneralRe: attach an icon to mouse cursor Pin
Hamid_RT9-Dec-08 20:49
Hamid_RT9-Dec-08 20:49 
First is correct
it replaces new object with previous.

Second:
(iconinfo.hbmColor = hXorMask)=hXorMaskDC?
You made a handle bitmap hXorMask on the CreateCursorFromBitmap and its set to NULL then you pass this handle to GetMaskBitmaps on the last parameter GetMaskBitmaps(...,...,...,hXorMask);but I think you dont see declare of GetMaskBitmaps:
GetMaskBitmaps(HBITMAP hSourceBitmap, COLORREF clrTransparent,
HBITMAP &hAndMaskBitmap, HBITMAP &hXorMaskBitmap)

<br />
a little sample of & (address of operator)<br />
int i ; <br />
  int& i2 = i;  // Define a reference to the object<br />
  i=100;<br />
<br />
int c=i2;  //the result is 100 <br />
c=100;<br />
i2=100; <br />
i=100;<br />


Now I think you know why iconinfo.hbmColor= hXorMask; because after the loop you have ::SelectObject(hXorMaskDC,hOldXorMaskBitmap);


Third:
You must delete DC after finish wrok but this question is return to previous question and your answer is last parameter of this function
.....HBITMAP &hXorMaskBitmap)
before delete it has address of hbitmap.


(BTW one more thing about DeleteDC: if your DC is of GetDC() you cant use of DeleteDC and you must be use of ReleaseDC.;))



vikas choudhry wrote:
these are only small doubt i have


Laugh | :laugh:

Of one Essence is the human race
thus has Creation put the base
One Limb impacted is sufficient
For all Others to feel the Mace
(Saadi )

GeneralRe: attach an icon to mouse cursor Pin
vikas choudhry9-Dec-08 21:27
vikas choudhry9-Dec-08 21:27 
GeneralRe: attach an icon to mouse cursor Pin
Hamid_RT10-Dec-08 20:06
Hamid_RT10-Dec-08 20:06 
GeneralRe: attach an icon to mouse cursor Pin
vikas choudhry11-Dec-08 0:00
vikas choudhry11-Dec-08 0:00 
GeneralRe: attach an icon to mouse cursor Pin
Hamid_RT11-Dec-08 2:46
Hamid_RT11-Dec-08 2:46 
QuestionThumbnail dialog problem Pin
Pryabu4-Dec-08 17:25
Pryabu4-Dec-08 17:25 
QuestionThumbnail dialog Problem Pin
Pryabu4-Dec-08 17:17
Pryabu4-Dec-08 17:17 
QuestionDBCS problem Pin
David Crow4-Dec-08 9:28
David Crow4-Dec-08 9:28 
AnswerRe: DBCS problem Pin
YoungJin Shin4-Dec-08 20:23
YoungJin Shin4-Dec-08 20:23 
QuestionUsing CMFCStatusBar class How do you Set the Text for a Label(dynamically) Pin
Larry Mills Sr4-Dec-08 3:42
Larry Mills Sr4-Dec-08 3:42 
AnswerRe: Using CMFCStatusBar class How do you Set the Text for a Label(dynamically) Pin
Hamid_RT4-Dec-08 3:51
Hamid_RT4-Dec-08 3:51 
GeneralRe: Using CMFCStatusBar class How do you Set the Text for a Label(dynamically) Pin
Larry Mills Sr4-Dec-08 4:33
Larry Mills Sr4-Dec-08 4:33 
QuestionRe: Using CMFCStatusBar class How do you Set the Text for a Label(dynamically) Pin
led mike4-Dec-08 4:44
led mike4-Dec-08 4:44 
AnswerRe: Using CMFCStatusBar class How do you Set the Text for a Label(dynamically) Pin
Larry Mills Sr4-Dec-08 5:11
Larry Mills Sr4-Dec-08 5:11 
GeneralRe: Using CMFCStatusBar class How do you Set the Text for a Label(dynamically) Pin
led mike4-Dec-08 5:27
led mike4-Dec-08 5:27 
GeneralRe: Using CMFCStatusBar class How do you Set the Text for a Label(dynamically) Pin
led mike4-Dec-08 4:34
led mike4-Dec-08 4:34 
GeneralRe: Using CMFCStatusBar class How do you Set the Text for a Label(dynamically) Pin
Mark Salsbery4-Dec-08 5:23
Mark Salsbery4-Dec-08 5:23 
GeneralRe: Using CMFCStatusBar class How do you Set the Text for a Label(dynamically) Pin
Larry Mills Sr4-Dec-08 5:50
Larry Mills Sr4-Dec-08 5:50 

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.