• Welcome to PlanetSquires Forums.
 

standard scroll bar and scroll bar control: how to distinguish

Started by Wilko Verweij, December 23, 2014, 05:09:48 PM

Previous topic - Next topic

Wilko Verweij

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

Wilko Verweij

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...

Paul Squires

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

Wilko Verweij