RecordSet Object
Visual Basic uses an object called RecordSet to hold your table. To declare such an object and to open the table, do this:Dim rsMyRS As RecordSetSet rsMyRS = dbMyDB.OpenRecordSet("MyTable", dbOpenDynaset)
What happened there? Well, I declared a RecordSet object and used the Database object's OpenRecordSet method to open a table of type Dynaset. You can open a RecordSet in several modes. VB's online help file explains the different modes and what they ar e for. The Dynaset mode is the mode I use mostly. It gives you a RecordSet that you can add, delete and modify records in.
No comments:
Post a Comment