Forms Field Navigation

  • Thread starter Thread starter Gwen
  • Start date Start date
G

Gwen

Hello,

I'm trying to figure out how to duplicate the field
navigation like excel, so that on a continuous form the
user can use the arrow keys to select his/her field.

Can anyone offer help on achieving this?

thanks in advance!

Gwen.
 
I do this all the time.

You need to set the forms keypreview property to yes, and then paste in the
following code into the on-key down event:


' key hand

Select Case KeyCode

Case vbKeyUp
KeyCode = 0
On Error Resume Next
DoCmd.GoToRecord acActiveDataObject, , acPrevious

Case vbKeyDown
KeyCode = 0
On Error Resume Next
DoCmd.GoToRecord acActiveDataObject, , acNext

End Select

Here is some screen shots of where I use the above code. I also give you
some ideas on how to use continues forms in place of grid controls:

http://www.attcanada.net/~kallal.msn/Articles/Grid.htm
 
I was actually hoping for some 1000+ line of code to make
me feel better, you obviously earned your MVP to do it in
10... I feel lame?

Thank you for the help it works perfect!

Gwen.
 
Back
Top