|
-
May 10th, 1999, 06:38 PM
#1
Spin Control
An Spin control next to an Edit control increases by down arrow and decreases by up arrow...Strange as it seems ,how do you swap this functionality.
-
May 10th, 1999, 06:42 PM
#2
Re: Spin Control
The reason for this is the maximum value is 0 and minimum value is 100.hrm..
Try setting maximum to 100 and minimum to 0, or whatever numbers you want to use. This should work.
-
May 10th, 1999, 07:09 PM
#3
Re: Spin Control
Max 100 and Min 0 is set by the control itself and i have not set them....
and there is no ref to Min and Max on the aproperties on the CTRL.
-
May 11th, 1999, 02:24 AM
#4
Re: Spin Control
Hi,
with Your Spin Control You have a message handler:
OnDeltapos(NMHDR* pNMHDR, LRESULT* pResult)
Class wizard defines a variable in it:
NM_UPDOWN* pNMUpDown = (NM_UPDOWN*)pNMHDR;
The numbers are changed with the value
pNMUpDown->iDelta
To swap it You only have to multiplicate it with -1.
BTW: the direction of the spin button is exactly the same as it is with scrollbars. So, lots of people (including me) would expect the standard behavior...
HTH
Rudolf
-
May 11th, 1999, 05:29 AM
#5
Re: Spin Control
void CSpinButtonCtrl::SetRange( int nLower, int nUpper );
-
May 12th, 1999, 10:31 PM
#6
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
|