Open 2nd form after click in record in Subform

G

Guest

Hello!

Explanation:
I have a main Form based in T_Form and Subform based in T_Subform.
In main Form I have a combo box; when we click in combo row, open the
Subform and show us all records that selection, with some fields of each
record.
To here, work fine.

Now:
I woul like click in first field of one record - showed in SubForm - and
open the second form, based in T_SubForm too, with another fields of this
record.

How do I this, please?
Thanks in advance.
an
 
A

Arvin Meyer [MVP]

Assuming that you have the record's ID in a control, even if visible is set
to false. Try using the double-click instead as it won't be fired every time
someone click to edit or select the record. Here's some aircode, just
substitute the correct names:

Sub txtFirstTextBox_DblClick(Cancel As Integer)
DoCmd.OpenForm "SecondForm", , , "ID =" & Me.txtID
End Sub
--
Arvin Meyer, MCP, MVP
Microsoft Access
Free Access downloads:
http://www.datastrat.com
http://www.mvps.org/access
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top