Hello Experts,
1) There is a maintable[T1], 10/10th field (R) which is a Multiple Selection Listbox inheriting values from another table[T2]. T2 is single column table with data to make a listbox.
2) A mainform[F1] with some filter controls
3) A subform[F2] based on the T1 in the mainform.
4)The R(Remarks) in F2 is deleted & replaced with a Listbox[LB] - It being a) Control Source to [T1].(Remarks), b) Row Source to T2, c) Allow Value List Edits to F2.
Requirement: R should be automated based on 9/10 field. The value of R in F2 should be set to "OK" 1st value in the in the list box.
My VBA:
Private Sub Invoice_Date_AfterUpdate() 'Invoice_Date is the 9/10 field
Me.Remarks.Selected(1) = True
Me.Remarks.value = Me!Remarks.Selected(1)
End Sub