Sub-form, double click on record to open…

dcc15

New member
Local time
Today, 15:41
Joined
Nov 26, 2007
Messages
9
Hi everyone,
I am stepping into sub-forms (Finally). I am creating a form to perform administrative functions (Verifying/closing records) on my DB. What I need some help on, is filtering the records for editing (in the sub-forms), I'd like to have one (maybe two) TextBox/Controls where I can enter a Record ID (I have two tables the same ID as FK's) and have the sub-forms filtered for only the records with the ID entered. Here’s what I have come up with so far, for an unbound control on the main form to get what I want on the two sub forms (seems to be doing the trick for this part):

Private Sub NcNumSearch_AfterUpdate()
Me.[F_CA_AdminSub].Form.Filter = "([NcNum] = '" & Me!NcNumSearch & "')"
Me.[F_CA_AdminSub].Form.FilterOn = True

Me.[F_RMA_AdminSub].Form.Filter = "([NcNum] = '" & Me!NcNumSearch & "')"
Me.[F_RMA_AdminSub].Form.FilterOn = True
End Sub

What I'd like to be able to do on top of this, is add the ability to double click on the ID of either sub-form (Datasheet view) to open a corresponding form, in that record for editing (subforms only contain minimal fields for closing records that I (or another user) Know the details are complete (records have several large text/memo fields). I've seen this in an "example" somewhere but can't seem to find now. Any help on doing this would be appreciated.
Thanks
DCC
 
I'm not 100% sure I follow the last paragraph. However, If you want to double click an ID field within one form and open another form that relates to the same record ID, perhaps this might be of use:

http://office.microsoft.com/en-us/templates/TC010184611033.aspx?pid=CT101426031033


Download the time and billing sample and go into the 'projects' option and double click the 'Project Manager' cbo control, there you'll be taken to a form that is linked to the same record ID. you can look at the code and how it's bound That might give you some ideas.

regards.
 
Thanks, I was able to figure it out, the example DB seems to have some interesting features (I've saved it).
Thanks,DCC
 

Users who are viewing this thread

Back
Top Bottom