Solved

MS Access : Goto record

Posted on 2004-08-09
2
1,022 Views
Last Modified: 2012-06-21
Hi all,

I am relatively new to Access. My question is pretty basic, so hopefully the aswer will be easy for you guys.

I have a main form to manage my contacts, and a "Search Contacts" form. This searchform works great : I can fill in the search criteria, hit the 'search' button, and it shows all records that fulfill the criteria. Next to every record there is a "Goto" button, that launches the main form with the selected record. I used the
 
    docmd.Openform formname,,,criteria

methode to open the contactsform with the resulting record.

But in this contactsform, there is only one record in the recordset.
Is there a way that when I click on the "Goto" button in the searchform, that the mainform is opened with all records in the recordset, but the bookmark is set correctly so the chosen record is visible.
I allready tried to copy the bookmark from my search-query to the recordset of my main form, but these are incompatible.

Thx
0
Comment
Question by:Thomas_VDB
2 Comments
 
LVL 26

Accepted Solution

by:
dannywareham earned 50 total points
ID: 11751544
If you have a record number in your table (say RecordID), you can fetch the record via:

Me.Recordset.FindFirst "RecordID=" & "YourEntry".Value

In the onload of the form.
0
 

Author Comment

by:Thomas_VDB
ID: 11751870
Thanks a lot !
0

Featured Post

Complete VMware vSphere® ESX(i) & Hyper-V Backup

Capture your entire system, including the host, with patented disk imaging integrated with VMware VADP / Microsoft VSS and RCT. RTOs is as low as 15 seconds with Acronis Active Restore™. You can enjoy unlimited P2V/V2V migrations from any source (even from a different hypervisor)

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Most if not all databases provide tools to filter data; even simple mail-merge programs might offer basic filtering capabilities. This is so important that, although Access has many built-in features to help the user in this task, developers often n…
Phishing attempts can come in all forms, shapes and sizes. No matter how familiar you think you are with them, always remember to take extra precaution when opening an email with attachments or links.
In Microsoft Access, learn different ways of passing a string value within a string argument. Also learn what a “Type Mis-match” error is about.
With Microsoft Access, learn how to specify relationships between tables and set various options on the relationship. Add the tables: Create the relationship: Decide if you’re going to set referential integrity: Decide if you want cascade upda…

776 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question