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

Go from one form to another form

Status
Not open for further replies.

supportguy21

Technical User
Dec 15, 2002
13
CA
Hello,

I have two forms that are bound to the same table. One form displays all the table fields per record. The other form is a grid-view that displays only selected fields. Through the grid-view, users can view 10 records at a time.

Background - some of the users wanted to be able to view multiple records at once. If there was a record where they want to view all the fields, they can quickly 'jump' from the grid-view form to the record-view form to that specific record.

Therefore, what I would like to do is have the user select a record from the grid-view form and then go to that record in the record-view form.

Thanks, sg21
 
Why not just use one form. The user can then select either form view or datasheet view. Form view will show them just one record, datasheet view will show them muliple records. In datasheet view you can hide the fields you don't want the user to see.
 
Hi,

I have to agree with FancyPrairie. It would be easier for you and the user if you used one form. However, if that's not an option try this:

- Change the names to match your particular fields
- SingleRecordForm should be changed to match the name of the form that is being opened; UniqueID should be changed to the name of a field that is common among all tables and holds unique values

'This passes the value from one form to the other
Forms!SingleRecordForm.UniqueID = Me!UniqueID

'This sets your bookmark property to the passed value and does a search to return that particular record
Me.RecordsetClone.Findfirst "[UniqueID] = " & Me![UniqueID] Me.Bookmark = Me.RecordSetClone.Bookmark

HTH,

jbehrne
 
Well that was easy! Thanks FancyPrairie and jbehrne - much appreciated!

SG21
 
Why not insert a subform of the same form set to form view, with the main form set to datasheet view. Use the expand buttons for each record to open that record in form view.

Assuming you are using Access 2000.

JDTTEK
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top