Solved

Arrow down from One line to the next on continuous form

Posted on 2014-01-22
2
368 Views
Last Modified: 2014-01-23
I have a continuous form in my application that is set up to enter repetative data.

There are five fields across the screen with "Account' being the first.

I have it set up to automatically carry all but the account information from the prior line to each new line that is entered.

The user has requested to be able to go from the account field on one line directly to the account on the next line by pressing the arrow down key.  I know I have done this in the past for other users but I don't remember how.

I know there is a property on the form that must be set but can't remember the details.

How do I provide the users with this ability?
0
Comment
Question by:mlcktmguy
2 Comments
 
LVL 29

Accepted Solution

by:
IrogSinta earned 250 total points
ID: 39801804
Add the following code to a module:
Function KeyUpDown(ByRef vKeycode As Variant) As Boolean
    On Error Resume Next
    If vKeycode = vbKeyDown Then
        DoCmd.GoToRecord , , acNext
    Else If vKeycode = vbKeyUp Then
        DoCmd.GoToRecord , , acPrevious
    End If
End Function

Open in new window

Then add OnKeyUp and OnKeyDown events to each of the fields in your continuous form and put this code in their procedures:
Call KeyUpDown(KeyCode)

Ron
0
 
LVL 1

Author Closing Comment

by:mlcktmguy
ID: 39803312
Excellent
0

Featured Post

Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

It took me quite some time to sort out all the different properties of combo and list boxes available from Visual Basic at run-time. Not that the documentation is lacking: the help pages are quite thorough and well written. The problem was rather wh…
Overview: This article:       (a) explains one principle method to cross-reference invoice items in Quickbooks®       (b) explores the reasons one might need to cross-reference invoice items       (c) provides a sample process for creating a M…
Familiarize people with the process of utilizing SQL Server functions from within Microsoft Access. Microsoft Access is a very powerful client/server development tool. One of the SQL Server objects that you can interact with from within Microsoft Ac…
With Microsoft Access, learn how to specify relationships between tables and set various options on the relationship. Add the tables: Create the relationship: Decide if you’re going to set referential integrity: Decide if you want cascade upda…

757 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now