Re: ADO Bookmark status



I think this is a very simple question.

Oh the question is simple, the answer , if there is any at all, might not
be.

I get a book mark in a variant using C++ code like below.

_variant_t bookmark;
bookmark=GetAdoRecordsetPtr()->Bookmark;

Why are doing that?
How do you know that the Recordset supports bookmarks?

Now I want to know if the bookmark is any good. So I would use code
something like this:

No such method is provided. It does not exist.
It will be valid if the Recordset supports bookmarks and you have taken a
previous position that you wish to return to.
It is entirely like the validity of fseek() in C/C++ in text mode - you can
only return to a valid position returned from ftell()

So if pRs->Supports(adBookmark) returns true you can use Bookmarks
And that tends to be
All client sided-cursors
All server sided-cursors except adForwardOnly (obvious really, since the
cursor does not support MovePrevious(), how can you move back?)
Dynamic cursors might be a problem is another user has been and deleted the
record you bookmarked on.

I just can't find what "VALID" should be or what is the right equivalent
method for "IsBookMarkValid()".

Do you know what these are or where I can find them?

They dont exist.

Stephen Howe


.



Relevant Pages

  • Re: Zeilen im Datagrid bewegen
    ... Was kannst Du wie beim DG zur Entwurfszeit mit dem ADODC bearbeiten? ... > datagrid.rebind die bookmarks wieder löscht. ... Datensatz machen. ... solange das Recordset nicht neu geladen wird. ...
    (microsoft.public.de.vb)
  • Re: Bookmark 3159 nach Update
    ... Es machen wohl die von Access automatisch ... eingestellten Bookmarks Probleme. ... Es geht um ein Treeview, das mit Daten aus Recordset rs_show beliefert ...
    (microsoft.public.de.access)
  • one column listbox, multiple bookmarks, spreadsheet link
    ... spreadsheet using the MVP method from "Load a ListBox from a Named ... different bookmarks on the document should be filled out. ... ' Set the number of Columns = number of Fields in recordset ...
    (microsoft.public.word.vba.userforms)
  • Re: ADODB.Recordset.Bookmark
    ... Thanks for the info. I'm not really a beginner developer, just new to ADO ... I changed the cursor type to static, and bookmarks work, but now I can't ... property of the connection or recordset that can tell me whether the ...
    (microsoft.public.vb.database.ado)
  • Re: me.undo
    ... > First of all, thanks for explaining Recordset Clone and Bookmarks to me, ... >> Wayne Morgan ... >> MS Access MVP ...
    (microsoft.public.access.modulesdaovba)