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 gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Requery Query? 1

Status
Not open for further replies.

kpryan

Technical User
Aug 24, 2005
282
US
Hi all,
When on a form I uses the re query command .. the form always goes to the first record.Is there a way when the re query command is used that it stays at that same record?

Many thanks,

Ken
 
The only way is to save the unique key of the location and to use, say, the recordset clone and bookmark to return to that location after the requery.
 
Thanks Remou,
for your reply, but how do you do that.? I'm not sure where to start with this.

Ken
 
Are you using a button or code to requery? If so, please post it.
 
Howdy kpryan . . .

. . . perhaps this:
Code:
[blue]   Dim hldID
   
   hldID = Me![purple][b][i]PrimaryKeyName[/i][/b][/purple]
   Me.Requery
   Me.Recordset.FindFirst "[[purple][b][i]PrimaryKeyName[/i][/b][/purple]] = " & hldID[/blue]

Calvin.gif
See Ya! . . . . . .

Be sure to see thread181-473997
Also faq181-2886
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top