VBcoders Browse New Submit Contact Sign In

No account? Register free

Forgot password?

Proper ADO Recordset

Jeff Jonsson  (1 Submission)   Databases/Data Access/DAO/ADO   Visual Basic 3.0   Advanced   Wed 3rd February 2021

To remedy difficiencies in ADO, namely single criteria in the .FIND method.
We encapsulated an ADODB.Recordset within a vb6 class module, and created four methods (FindFirst, FindLast, FindNext, FindPrevious) which allow for more that one criteria.

Inputs
Use is almost exactly that of a standard ADODB.Recordset.

Assumes
Just drop the class module into a project, and rename all: Dim aRecSet as ADODB.Recordset to: Dim aRecSet as ProperADORecordset then CTRL-F5 to find and replace all Open/Close methods with OpenIt/CloseIt. Any new properties/methods simply pass arguments/return values between the encapsulated ADODB.Recordset and the created class module.

Returns
Returns less headaches.

Side Effects
First, not all properties/methods have been emulated. Easy enough to do though. Left as an exercise. Second, due to vb limitations, Open/Close not supported, but renamed as OpenIt/CloseIt.

Rate Proper ADO Recordset (7(7 Vote))

Download Proper ADO Recordset

Proper ADO Recordset Comments

No comments yet — be the first to post one!

Post a Comment

0/1000 characters