DoCmd.OpenForm...acFormAdd

  • Thread starter Thread starter Kyle Jedrusiak
  • Start date Start date
K

Kyle Jedrusiak

I make the following call in my code...

DoCmd.OpenForm gkTopSheetEditForm, , , , acFormAdd, acDialog

The form comes up all works as expected, I can start to enter data but if I
accidentally scroll with the mouse wheel the form moves to another new
record.

How can I prevent this?

Kyle!
 
Kyle Jedrusiak said:
I make the following call in my code...

DoCmd.OpenForm gkTopSheetEditForm, , , , acFormAdd, acDialog

The form comes up all works as expected, I can start to enter data
but if I accidentally scroll with the mouse wheel the form moves to
another new record.

How can I prevent this?

Stephen Lebans has a solution for disabling the mouse wheel:

http://www.lebans.com/mousewheelonoff.htm
 
Hi Kyle,

that Leban's solution was developed because Access does not provide an
internal solution.

If you work with Access XP, then you'll have On Mouse Wheel event to work
with.

[]
Luiz Cláudio C. V. Rocha
São Paulo - Brazil
MVP Office
 
Kyle Jedrusiak said:
Thanks but I'd like an easy solution directly in Access if it exists.

There isn't one, unless they've added it to Access 2003. In Access 2002
you may be able to do something with the MouseWheel event, but I suspect
you'll have to do a lot of programming even with that. I'd stick with
Stephen's solution for now.
 
I've had the same problem, and I think I solved it by
setting the Form Cycle property to "Current Record" (Form
properties /Other/Cycle)
 
Back
Top