ACC2000: How to Simulate a Dynamic Counter in a Table or a Query to Count Records (199679)
The information in this article applies to:
This article was previously published under Q199679 This article applies only to a Microsoft Access database (.mdb).
Advanced: Requires expert coding, interoperability, and multiuser skills.
SUMMARY
This article contains sample Visual Basic for Applications code that you can use to select an incremented number of records from an existing table or query and to create a dynamic counter value for those records in a new table. You can use this sample code for the following purposes:
- To create a new table with an AutoNumber field to act as a record counter for a pre-existing set of records.
- To return every Nth record from a table or query and to store the results in a new table with an AutoNumber field, which simulates a record counter.
- To return every Nth record from a table or query and to store the results in a new table.
REFERENCESFor additional information about how to test if a table or query already exists within a database, click the article number below
to view the article in the Microsoft Knowledge Base:
210398 ACC2000: Sample Code to Check for Table or Query in a Database
Modification Type: | Major | Last Reviewed: | 6/24/2004 |
---|
Keywords: | kbdtacode kbhowto kbusage KB199679 |
---|
|