February 2019

How To Have Access VBA Link Tables Programmatically

This table relinking procedure is a really good example of how to use VBA to link your tables programmatically, and how to have MS Access refresh linked tables automatically. It allows re-linking all tables to a selected drive source (the folder the backend database is in). In this example, all of the tables that need […]

Continue Reading

MS Access Subform Navigation Buttons

In the following example the ms access subform gets its value from parent form. In our example we have a main form which shows the customers and the subform which shows all the orders for the customer: Independently the forms function by themselves, however it is more meaningful if they are combined. This is how […]

Continue Reading

MS Access Running Count With String Column And Duplicates

In my previous post, https://vbahowto.com/ms-access-running-count-with-duplicates/, the DCount counter, works fine when you have a numeric value, and it works fine when you do the VBA counter when you do it on numeric column values, but what about counters on string columns with duplicates? MS Access Running Count With String Column And Duplicates Since an Access […]

Continue Reading

MS Access Running Count With Duplicates

This post is a response to a video I have on Youtube: MS Access Running Counter In Query “After running your solution in different databases, I found out that it only works if there are no duplicate values within the Number field (in your tblRunningSum). Once there are duplicate values, the row numbering gets corrupted. […]

Continue Reading

How to programmatically create an Access DSN

When I was working on a project at Exxon, I had to load Access on startup to connect to a DSN. Here is how I implemented it (I don’t remember where I found the code): Private Sub Form_Open(Cancel As Integer) ‘#####================================================================================ ‘## ‘## ‘## Purpose: ‘## For use in scripts that require SQL System DSNs […]

Continue Reading

How To Create Dynamic Combo Boxes In Access

This post will show you how you can create dynamic combo boxes in MS Access. In our example we have 2 tables, a list of wards and a list of rooms in those wards. We want to be able to select a ward and then get the rooms available in that ward. This is fairly […]

Continue Reading