Up Down Control

Started by Dennis Allen, March 18, 2015, 05:07:03 PM

Previous topic - Next topic

Dennis Allen

Hi,

I looked at the posts I found here on using the control. I placed the suggested code in the custom handler of the form on which the Up Down resides, and nothing happens.
The main form is blank except for the up down control.

here is the example I found

   Local pUpDown As NM_UPDOWN Ptr
   
   Select Case wMsg
      Case %WM_NOTIFY
         pUpDown = lParam
         If @pUpDown.hdr.idFrom = IDC_FRMCREATETBL_UPDOWN1 Then
            If @pUpDown.hdr.Code = %UDN_DELTAPOS Then
               If @pUpDown.iDelta = -1 Then 'Down
                  MsgBox "DOWN"
               Else   'Up
                  MsgBox "UP"
               End If                     
            End If                           
         End If   
      Case Else                             
   End Select                                     

There must be something about the pointer that I am missing, Can you help?
Thank you in advance.

Ron

Elias Montoya


Can you put more code? Case else not required, otherwise this looks good.
Win7, iMac x64 Retina display 5K, i7-5820K 4.4 ghz, 32GB RAM, All updates applied. - Firefly 3.70.

Dennis Allen

Hi,

I appreciate you help. I was using
HWND_FORM1_UPDOWN1
instead of

IDC_FORM1_UPDOWN1

Dennis Allen

Hi,

And thank you much as my wife's cat pushed my hand away during my response.
best wishes,

Ron

Elias Montoya

 Yup, it sounded like a wrong handle mistake.  :)
Win7, iMac x64 Retina display 5K, i7-5820K 4.4 ghz, 32GB RAM, All updates applied. - Firefly 3.70.