void SetBookmark( COleVariant varBookmark );
throw( CDaoException, CMemoryException );
Parameters
varBookmark
A COleVariant object containing the bookmark value for a specific record.
Remarks
Call this member function to position the recordset on the record containing the specified bookmark. When a recordset object is created or opened, each of its records already has a unique bookmark. You can retrieve the bookmark for the current record by calling GetBookmark and saving the value to a COleVariant object. You can later return to that record by calling SetBookmark using the saved bookmark value.
Note that if you are not creating a UNICODE recordset, the COleVariant object must be explicitly declared ANSI. This can be done by using the COleVariant::COleVariant( lpszSrc, vtSrc ) form of constructor with vtSrc set to VT_BSTRT (ANSI) or by using the COleVariant function SetString( lpszSrc, vtSrc ) with vtSrc set to VT_BSTRT.
For more information about finding records, see the article DAO Recordset: Recordset Navigation in Visual C++ Programmer's Guide. For related information, see the topics "Bookmark Property" and Bookmarkable Property" in DAO Help.
CDaoRecordset Overview | Class Members | Hierarchy Chart
See Also CDaoRecordset::GetBookmark