March 19th, 2010 03:32 AM
#1
how get a x,y postion of control
hai i want to get a cursor position for the buttoncontrol in mfc,give me sample code
Thanks
March 19th, 2010 03:38 AM
#2
Re: how get a x,y postion of control
What is a "cursor position" of a buttoncontrol?
A button control in MFC is represented by a CButton instance.
CButton is derived from CWnd.
To get the screen coordinates of a CWnd call
Code:
CRect r;
pButton->GetWindowRect(&r);
All this is well described in the MSDN.
With regards
Programartist
March 19th, 2010 03:52 AM
#3
how get a x,y postion of control
Thanks Programartist i want to do page up and page down access in a dialog window, upto the button i want to move down/up , so i want to move the cursor position . give me sample code
Thanks
Sona
March 19th, 2010 07:07 AM
#4
Re: how get a x,y postion of control
Originally Posted by
goldenswarna
give me sample code
Sona
You may want to rephrase that so it's less demanding. Nobody is here to just give you sample code on demand.
Posting Permissions
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
Forum Rules
Click Here to Expand Forum to Full Width
Bookmarks