var sidebar_align = 'right';
var content_container_margin = parseInt('290px');
var sidebar_width = parseInt('270px');
Unanswered: Select item in a list2 based on selection in list1 and retain focus in list1
Trying to learn Access. Using VB.
I have a form with a list of items from table1 and another list of items from table2. They have an ID field in common with a 1-many relationship. Both tables have less than 5 rows.
Items in List1 are ordered by SubID, items in list2 are ordered by ID.
In the form OnLoad event, I select the first row of List1.
Need help with what needs to happen next.
I want to determine the corresponding ID of the selected row in List1 and find and select that item in List2, then move focus back to List1
Row Source Type: is Table/Query
Row Source: Select T1.SubID, T1.ID, T1.Name From T1 ORDER BY T1.SubID
Similarly for List2
Look at "DemoList1List2ComboA2000.mdb" (attachment, zip).
Look at Tables, Form1(VBA), Relationships.
Open form and try.
I thin you need something like this.
Put Sub List2_AfterUpdate, and put the code:
Last edited by MStef-ZG; 10-14-11 at
Tags for this Thread