Closed DeerSpotter closed 2 years ago
your demo doesnt show any vertical scroll.
@DeerSpotter The demo has vertical scroll by default. Horizontal scroll only works if the SHIFT key is down/pressed. I have tested on multiple machines and it works fine.
Please check if your SHIFT key is stuck or maybe try disconnecting the keyboard. Also, if you are using specialized mouse software like "X-Mouse Button Control" then turn it off and then try the demo again.
Another question, how can i disable shift key altogether and have it automatically hook on form initialize?
I'm now looking for a way to code in keyboard press shift down on form initialize and release shift on form close.
Unless you have a better idea.
@DeerSpotter In the MouseScroll.bas
module there is a function that returns the state of the SHIFT key. Try replacing:
Private Function IsShiftKeyDown() As Boolean
Const VK_SHIFT As Long = &H10
'
IsShiftKeyDown = CBool(GetKeyState(VK_SHIFT) And &H8000) 'hi-order bit only
End Function
with:
Private Function IsShiftKeyDown() As Boolean
IsShiftKeyDown = False
End Function
and then see if the vertical scroll works. Let me know how it goes
@DeerSpotter In the
MouseScroll.bas
module there is a function that returns the state of the SHIFT key. Try replacing:Private Function IsShiftKeyDown() As Boolean Const VK_SHIFT As Long = &H10 ' IsShiftKeyDown = CBool(GetKeyState(VK_SHIFT) And &H8000) 'hi-order bit only End Function
with:
Private Function IsShiftKeyDown() As Boolean IsShiftKeyDown = False End Function
and then see if the vertical scroll works. Let me know how it goes
It still requires me to press shift to scroll. Even if i say = true still requires shift to be pressed.
It still requires me to press shift to scroll. Even if i say = true still requires shift to be pressed.
@DeerSpotter At this stage, I am pretty certain that another software on your computer is hooking the mouse and not passing the information via CallNextHook
. If you have any mouse software (like X-Mouse Button Control) just disable it and then try again
It still requires me to press shift to scroll. Even if i say = true still requires shift to be pressed.
@DeerSpotter At this stage, I am pretty certain that another software on your computer is hooking the mouse and not passing the information via
CallNextHook
. If you have any mouse software (like X-Mouse Button Control) just disable it and then try again
Okay its working, Thank you. That's what it was. Is there a way to make it work with X-Mouse Button Control?
would 3dConnection program also do the same thing as x-mouse button control?
@DeerSpotter Maybe. Try closing it before trying the demo and see how it goes.
Okay its working, Thank you. That's what it was. Is there a way to make it work with X-Mouse Button Control?
Yes. See this
who need horizontal scroll?
That's not what is needed in VBA its vertical scroll.