Lưu ý
Cần có ủy quyền mới truy nhập được vào trang này. Bạn có thể thử đăng nhập hoặc thay đổi thư mục.
Cần có ủy quyền mới truy nhập được vào trang này. Bạn có thể thử thay đổi thư mục.
Applies to: Access 2013, Office 2013
Closes an open Recordset.
Syntax
expression .Close
expression A variable that represents a Recordset2 object.
Remarks
If the Recordset object is already closed when you use Close, a run-time error occurs.
If you try to close a Connection object while it has any open Recordset objects, the Recordset objects will be closed and any pending updates or edits will be canceled. Similarly, if you try to close a Workspace object while it has any open Connection objects, those Connection objects will be closed, which will close their Recordset objects.
An alternative to the Close method is to set the value of an object variable to Nothing (Set dbsTemp = Nothing).