Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Access 2003 Bookmark ??

Status
Not open for further replies.

GummowN

Programmer
Jul 26, 2002
157
GB
I am using Access 2003

References
VBA
Access 11
OLE Automation
DAO 3.6
ADO 2.1

Background
I have a form from which I kick off another form - which then requeries the original form. I want to store the bookmark and then return to it when the kicked form closes

So when the form opens I store the original form bookmark as a variant.

So when the form closes it sets the bookmark from the variant

Problem
If I debug.print the bookmark I get the value ??
If I store the value in a control on the form I can see the value ??
If I debug.print the value of the control I get ??

By ?? I mean just that!!
?Forms!frm_deals!frm101.Form.Bookmark
??

Has anyone seen this AND fixed it in the past.

Thanks


If at first you don't succeed, try for the answer.
 
That is what Bookmarks look like. This will work:

[tt]avar = Me.Bookmark
Me.Recordset.MoveLast
Me.Bookmark = avar[/tt]

But I do not believe that what you are proposing will work, as the requery will change the Bookmark. You will need to save an ID instead and use the recordset to find it. Say:

[tt]intID = Me.ID
Me.Recordset.FindFirst "ID=" & intID[/tt]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top