Name

Recordset.Move Method — (Versions 2.0, 2.1, 2.5, 2.6)

Synopsis

                     recordset.Move NumRecords, Start
                  

The Move method of the Recordset object moves the position of the record pointer within the specified Recordset object.

Arguments

NumRecords (Long)

Specifies the number of records you want the record pointer to move.

Start (String or Variant)

Optional. Represents the bookmark from which you want the record pointer to move.

Description

The Move method of the Recordset object moves the record pointer a specified number of records. If the NumRecords argument is less than zero, the pointer is moved forward the desired number. If the NumRecords argument is greater than zero, the record pointer is moved forward the desired number of records.

If the current Recordset object supports bookmarks, then you can indicate a beginning position to start moving from with the Start argument. The Start argument should be set to a valid bookmark within the current Recordset object, and the record pointer will be moved the desired number of records from that point. If no bookmark is used, the record pointer will move from the current record.

Attempting to move to a point before the first record will result in moving to the record before the first record, which is a BOF. Attempting to move past the last record will result in the record pointer moving to the record after the last record, which is the EOF. In either case, if the Move method is used to attempt to move past the BOF or EOF, an error is generated. ...

Get ADO: ActiveX Data Objects now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.