O'Reilly logo

Microsoft® Access Projects with Microsoft SQL Server™ by Natascha Nicol, Ralf Albrecht

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Opening a Recordset

The Open method is used to open a recordset. The method is defined as follows:

recordset.Open [Source] [,ActiveConnection] [,CursorType] [,LockType] [,Options]

You can use the name of a table, a query, or a SQL table as the Source. The ActiveConnection parameter specifies which connection to use for filling the recordset. Enter CurrentProject.Connection to access the database connected to the project.

Use the CursorType parameter to define the recordset type. A cursor is a data structure that stores a query’s results. The cursor type determines a corresponding recordset object’s functions. The default value for CursorType is adOpenForwardOnly.

Table 13-4 lists the four valid CursorType constants, described earlier, that ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required