Access 2003 not in list event...

Posted on 2009-04-20
Medium Priority
Last Modified: 2012-05-06
I have an Access 2003 database which has a tblContact and a tblVehicle. On my form "Contacts" if someone tries to put in a vehicle NOT IN LIST, I have an event that tells them the item in not in the list, do they want to add it, and if they say YES, it opens up the vehicle data entry form  "vehicles" (see code below). They enter the new vehicle information, save it and it pops them back in the Contacts form populating the field. All this works great.

My question is this...when the new vehilce is being entered on the vehicle entry form, I wanted to put previous and next buttons so the user could scroll through all the entries in the tblVehicle as well as correct data entry errors from prior entries. This keeps the users out of the database. Problem is, I cannot scroll to anything from this form "vehicles" Is it possible? If so, how? I don't want to have to build another form just to allow maintenace on tblVehicles.
thx experts....Bob
Dim MsgStr As String
MsgStr = "'" & NewData & "' is not setup as a Vehicle. Do you want to add it?"
If vbYes = MsgBox(MsgStr, vbYesNo + vbQuestion, "New Vehicle?") Then
    DoCmd.OpenForm "vehicles", acNormal, , , acFormAdd, acDialog
    Response = acDataErrAdded
    Response = acDataErrDisplay
End If

Open in new window

Question by:bobrossi56
  • 4
  • 2
LVL 75

Accepted Solution

DatabaseMX (Joe Anderson - Microsoft MVP, Access and Data Platform) earned 2000 total points
ID: 24189712
Why not just open the exact form from a menu ... to do the maintenance.   But open it in normal view will all records, with maybe Allow Additions set to No.

Not sure I would want to overly complicated the Not In List function - which you already have working - and in addition to 'not in list addition' ... also ... at the same time, to allow for correcting other items in the list.


Author Comment

ID: 24189733
OK, that would work mx, but being a novice as yo know I am, how would I add said form to a menu?
LVL 75
ID: 24189763
The easy way to create custom Windows menus (standard) with no code:

Everything you need is here ... see this link:

Not sure it that article mentions it, but ... when you are in the Customize mode (dialog) ... if you hold down the Control key, you can drop and drag (ie, copy) menu items from one place to another ... handy for making a new menu that is similar another one.

Here is a related link also:



Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

LVL 75
ID: 24189776
I've created 100's and 100's of menus using this technique ... very cool.


Author Closing Comment

ID: 31572521
Once again, mx doesn't disappoint.
LVL 75
ID: 24189826
"Grade:  A - "Once again, mx doesn't disappoint."  "

Really Bob ... once you get the hang of creating custom menus ... you can say 'GoodBye' to the Access switch board - basically.  


Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Microsoft has changed the look and feel of Azure AD and Microsoft account sign-in pages so that you will have a more unified look and feel when moving between the two interfaces.
Microsoft Access has a limit of 255 columns in a single table; SQL Server allows tables with over 255 columns, but reading that data is not necessarily simple.  The final solution for this task involved creating a custom text parser and then reading…
If you’ve ever visited a web page and noticed a cool font that you really liked the look of, but couldn’t figure out which font it was so that you could use it for your own work, then this video is for you! In this Micro Tutorial, you'll learn yo…
In this video you will find out how to export Office 365 mailboxes using the built in eDiscovery tool. Bear in mind that although this method might be useful in some cases, using PST files as Office 365 backup is troublesome in a long run (more on t…

864 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