Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Mouse wheel control 2

Status
Not open for further replies.

techkenny1

Technical User
Jan 23, 2009
182
AU
Hi all,
Ive used the mouse control wheel code and on most forms it works ok
Ive used the code below. But on some forms the mouse wheel still works. Is there a reson for this.

Many thanks

'Turn the MouseWheel Off
Dim blRet As Boolean
blRet = MouseWheelOFF
 
Did you remember to Import the modMouseHook module? This contains the code for the function that does the actual work.

The Missinglinq

Richmond, Virginia

There's ALWAYS more than one way to skin a cat!
 
Hi Missingling,

Yes I have done all that. I have the code on the 'on load event'. On some forms it works ok, but others ???
Have tried all I can think of.

Many thanks
 
Are these in the same database? Once it's set off it should stay off unless you subsequently set it to Yes. I set mine in the OnLoad of my splash screen.

I even copied and pasted your code into a new form I made up and it works perfectly.

Not Importing the module is the usual mistake made, and I haven't heard of it malfunctioning for any other reason. Sorry!

The Missinglinq

Richmond, Virginia

There's ALWAYS more than one way to skin a cat!
 
How are ya techkenny1 . . .

What version Access?

See Ya! . . . . . .

Be sure to see thread181-473997 [blue]Worthy Reading![/blue] [thumbsup2]
Also faq181-2886 [blue]Worthy Reading![/blue] [thumbsup2]
 
Hi The Aceman1,
Access version 2002
I understand what Missinglinq is saying. And appreciate this help. I do have the code module imported.
For example I have an invoice form which I use the above code.
So I set it to enable the mouse wheel and it did. I then set it to disable the mouse wheel and it did that. But I have 2 forms in which this code just does not work. I even deleted the forms, reconstructed them again and still the same problem..
and yes.. I have the latest code module installed.
So the gremlins are at work.

many thanks
 
techkenny1 . . .

I gotta ask ... are you using the latest, [blue]version 2.2 March 15, 2005?[/blue] Also did you install via the latest by Lebans:
Lebans said:
[blue]MouseWheelHook is an MDB demonstrating how to use a MouseHook to turn off the MouseWheel. No more MouseWheel.DLL Hell! No DLL registration required. [purple]The MouseHook DLL is a standard Windows DLL. [red]Do not try to Register it or set a Reference to it from within Access.[/red][/purple] Just copy the included MouseHook.DLL into your Windows/System folder or into the same folder as your application MDB. One instance handles all Forms and SubForms so only call the functions once from a SINGLE Form.[/blue]
[blue]Your Thoughts? . . .[/blue]

See Ya! . . . . . .

Be sure to see thread181-473997 [blue]Worthy Reading![/blue] [thumbsup2]
Also faq181-2886 [blue]Worthy Reading![/blue] [thumbsup2]
 

Ooh, Ohh! As Tuttie Muldoon used to say! Aceman's quote reminded of a flaky thing! Sometimes, even within the same database, it'll work with the DLL in the Windows/System folder and sometines it has to be in the same folder as the database! And there's no rhyme or reason for this!

The Missinglinq

Richmond, Virginia

There's ALWAYS more than one way to skin a cat!
 
Hi to all who have helped with this one.
Yes I have done. all that you experts have advised.
I had the dll in the windows system 32. So i copied it to the folder where the db reside. Now its works. I guess that
missinglinq had the right concept. You just dont know what will make a microsoft product work!

many thanks to all
 

Sorry it took me so long to think of it! It really is quirky in that some forms in a db work fine with the DLL in the system folder and some require that it be in the database's folder.

Glad you got it working!

Linq

The Missinglinq

Richmond, Virginia

There's ALWAYS more than one way to skin a cat!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top