PlanetSquires Forums

Please login or register.

Login with username, password and session length
Advanced search  

Author Topic: standard scroll bar and scroll bar control: how to distinguish  (Read 594 times)

Wilko Verweij

  • Junior Member
  • **
  • Posts: 162
  • PB10 - FF3.7 User; Win 10
    • CHEAQS
standard scroll bar and scroll bar control: how to distinguish
« on: December 23, 2014, 05:09:48 PM »

Hi all,
I am aware of the difference between a "standard scroll bar" and a "scroll bar control" (see e.g. http://msdn.microsoft.com/en-us/library/windows/desktop/bb787527%28v=vs.85%29.aspx) and I can handle both of them, separately. But now I have a form where I have both a vertical standard scroll bar and a vertical scroll bar control.
Now if I click in the standard scroll bar, everything works as expected. However, if I click the scroll bar control, first the scroll bar control event is fired (that works as it should) but then, in addition, the event of the standard scroll bar is also fired! I've created a work-around, but I think there must be a way to avoid this. Does anyone know how to do that? As said, I've found a work-around so it's not urgent at all (don't let it spoil your Christmas ;)), but I just can't accept my clumsy work-around is the only way to do this.
Any suggestions?
Wilko
Logged

Wilko Verweij

  • Junior Member
  • **
  • Posts: 162
  • PB10 - FF3.7 User; Win 10
    • CHEAQS
Re: standard scroll bar and scroll bar control: how to distinguish
« Reply #1 on: December 23, 2014, 05:14:22 PM »

I now see that if you test for the WM_SCROLL message, you should be able to distinguish using the lParam value.
http://msdn.microsoft.com/en-us/library/windows/desktop/bb787577%28v=vs.85%29.aspx
But the WM_VSCROLL message in FireFly does not give access to lParam. Should I intercept this message as a custom message....?
 :-\
Confused...
Logged

Paul Squires

  • Administrator
  • Guru Member
  • *****
  • Posts: 8762
  • Windows 10
    • PlanetSquires Software
Re: standard scroll bar and scroll bar control: how to distinguish
« Reply #2 on: December 23, 2014, 11:26:47 PM »

Hi Wilko, in the Christmas rush so haven't tested your problem but you're right - use CUSTOM would be the easiest solution.
:)
Logged
Paul Squires
PlanetSquires Software
WinFBE Editor and Visual Designer

Wilko Verweij

  • Junior Member
  • **
  • Posts: 162
  • PB10 - FF3.7 User; Win 10
    • CHEAQS
Re: standard scroll bar and scroll bar control: how to distinguish
« Reply #3 on: December 25, 2014, 12:21:48 PM »

Yes, that did it :)
Logged