MouseWheelOnOff (1 Viewer)

ccflyer

Registered User.
Local time
Today, 03:45
Joined
Aug 12, 2005
Messages
90
Hey Guys,

I'm trying to implement the MouseWheelHook method in order to disable mouse scrolling on one of my forms, but I can't seem to get it to work.

Here's the link to MouseWheelHook:
http://www.lebans.com/mousewheelonoff.htm#Tips%20from%20Users%20of%20MouseWheelHook

This is what I've done so far:
1. Placed MouseHook.dll in the windows/system folder
2. Imported the module "modMouseHook" from the example database to mine
3. Placed the following code into the On Open() method of my form:
Code:
Dim blRet As Boolean
blRet = MouseWheelOFF

Any help would be very appreciated :)

Thanks,
Chris C.
 

Pleasure

Registered User.
Local time
Today, 12:45
Joined
Jul 26, 2005
Messages
44
To activate the hook use :
Dim blRet As Boolean
blRet = MouseWheelOFF(True, False)

To deactivate the hook :
Dim blRet As Boolean
blRet = MouseWheelON

and just in case place the .dll file in the same directory with your application-database. Do not register the dll in the registry
 

ccflyer

Registered User.
Local time
Today, 03:45
Joined
Aug 12, 2005
Messages
90
No luck... I tried changing my code to that, but it still allows the user to scroll to a new record using the mouse wheel.

-Chris
 

ccflyer

Registered User.
Local time
Today, 03:45
Joined
Aug 12, 2005
Messages
90
I think I found my problem... my users were hitting enter after each text box to go to the next. I have a calander control that was set as the next tab location (when I thought there were no more)... still a little strange, but when I changed the tab index of the calendar to a higher number, the scrolling ability stops.

Thanks,
Chris C.
 

Users who are viewing this thread

Top Bottom