By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,462 Members | 2,360 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,462 IT Pros & Developers. It's quick & easy.

Navigating main form with subform

P: n/a
ken
What is the best way to do this:
Table with primary key autonumber field and some text fields.
main form: views this table one record at a time.
subform: views whole table(datasheet view).

When ever I click on a record in the subform, the main form needs to
goto that record...

would I use the docmd.gotorecord to accomplish this? If so I need the
current offset in the table and I'm not sure how to get that...

Nov 13 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
ken wrote:
What is the best way to do this:
Table with primary key autonumber field and some text fields.
main form: views this table one record at a time.
subform: views whole table(datasheet view).

When ever I click on a record in the subform, the main form needs to
goto that record...

would I use the docmd.gotorecord to accomplish this? If so I need the
current offset in the table and I'm not sure how to get that...

Dim rst As DAO.Recordset
set rst = Forms!MainForm.Form.Recordsetclone
rst.FindFirst "WhateverIDNameIs = " & Me.WhatEverSubformIDFieldIs
Forms!MainForm.Form.bookmark = rst.Bookmark
rst.close
set rst = Nothing
Nov 13 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.