MouseWheel

  • Thread starter Thread starter Todd
  • Start date Start date
T

Todd

In a previous posting, someone asked the same question
that I have, which is "how do I turn off the mousewheel,
since it scrolls through records on a form which I don't
want the users of my database to be able to do."

In that previous posting the response directed me to this
website posting.

http://www.lebans.com/mousewheelonoff.htm

I tried using the solution here, but it didn't work. The
site says to just copy the .dll file into your system
folder or into the folder where the .mdb file is located.
This doesn't seem to work, so I'm thinking that there must
be some code or something required in my database to point
it to the .dll file.

Can anyone help?
 
Are you able to get the sample Form working containied within the MDB
you downloaed along with the DLL?

--

HTH
Stephen Lebans
http://www.lebans.com
Access Code, Tips and Tricks
Please respond only to the newsgroups so everyone can benefit.
 
Yes I got the sample to work. But to do that you have to
hit the "Stop Mousewheel" command button on the sample
form. Which I guess then activates the code?

I don't want my users to have to hit that button, so I
guess I'd like that code to be activated on startup and
deactivated on exit (if required).

So which portion of the code would I copy into my database
to do this, and would I simply add a line to my AutoExec
and Exit macros to RunCode the appropriate function, or
what? Am I way off base here???
 
Copy the module modMouseHook from the sample code into
your database and add this code

Dim blRet As Boolean
blRet = MouseWheelOFF

to your Form_load Sub Routine. This should work
 
Probably another dumb question, but what is my Form_load
Sub Routine? Is this the "On Load" event property for
each form?
 
Yes it is the "On Load" event property for a form
-----Original Message-----
Probably another dumb question, but what is my Form_load
Sub Routine? Is this the "On Load" event property for
each form?

.
 
You only need to call the function once in a single Form's On Load event
not for every form you load. It is an application wide MouseHook.
Remember you must alos unload the MouseHook in that same Form's Unload
event as per the code in the sample Form you downloaded.
--

HTH
Stephen Lebans
http://www.lebans.com
Access Code, Tips and Tricks
Please respond only to the newsgroups so everyone can benefit.
 
Back
Top