hard to follow for a beginner
Main Topics
Browse All Topicshow do you change the mouse cursor pointerat the start of the program and when the the mouse over a button.
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
Business Accounts
Answer for Membership
by: AlexVirochovskyPosted on 2000-05-01 at 07:20:46ID: 2765998
For set cursor in begin of apps: W)); /* new */
;
bsWin, TWindow)
/*modKeys*/, TPoint& point)
void TJobsWin::SetupWindow()
{
TWindow::SetupWindow();
....
SetClassLong(GCL_HCURSOR, /* changes cursor */
(LONG) ::LoadCursor(NULL,IDC_ARRO
....
}
For change cursor by mouse moving:
In begin of apps you prepare cursor:
hHand = ::LoadCursor(hInst, MAKEINTRESOURCE(IDC_HAND))
Where hHand -> property of you clsss
HCURSOR hHand
IDC_HAND reference you line in you REC file
For example:
#define IDC_HAND 1000
IDC_HAND CURSOR "mycursor.cur"
In destructor you must
::DestroyCursor(hHand);
In you DEFINE_RESPONSE_TABLE add line:
DEFINE_RESPONSE_TABLE1(TJo
.....
EV_WM_MOUSEMOVE,
.....
END_RESPONSE_TABLE;
You EvMouseMove may be as:
void TJobsWin::EvMouseMove(UINT
{
static bool bHand = FALSE;
static HCURSOR oldCursor;
bool bIn = InsideMyObject(point);
if (bIn) //inside
{
::SetCursor(hHand);
bHand = true;
}
else if (bHand && !bIn) //Out
{ //restore
::SetCursor(oldCursor); //or
::SetCursor(otherCursor); //or
bHand = false;
}
}
I hope, it helps. Alex
BTW : 20 PTS???