P
Pat
I am attempting to create a form to perform receiving of equipment and update
the asset tables with the equipment based on a location. When the form is
opened the first time, the data in the recordset is invalid. The
absoluteposition is -1. When you make another selection the reordset is
proper. BTW the combobox is bound to column 1 in the recordset. The text
box is updated from column 2.
I am using a unbound combobox (cboLocation) to query a table for a location
name. Then set a unbound textbox (txtLocID) with the location number.
Thisis the event I am using.
Private Sub cboLocation_AfterUpdate()
' Textbox - txtLocID
' Combobox - cboLocation - Uses the query below for data
' SELECT tblACOELocations.PHYS_LOC_N10, tblACOELocations.OLD_LOC_I
' FROM tblACOELocations
' ORDER BY tblACOELocations.PHYS_LOC_N10;
Me.txtLocID.SetFocus
Me.txtLocID = Me.cboLocation.Recordset.Fields("OLD_LOC_I").Value
Me.cboEmp.Requery
End Sub
Any help is appreciated.
the asset tables with the equipment based on a location. When the form is
opened the first time, the data in the recordset is invalid. The
absoluteposition is -1. When you make another selection the reordset is
proper. BTW the combobox is bound to column 1 in the recordset. The text
box is updated from column 2.
I am using a unbound combobox (cboLocation) to query a table for a location
name. Then set a unbound textbox (txtLocID) with the location number.
Thisis the event I am using.
Private Sub cboLocation_AfterUpdate()
' Textbox - txtLocID
' Combobox - cboLocation - Uses the query below for data
' SELECT tblACOELocations.PHYS_LOC_N10, tblACOELocations.OLD_LOC_I
' FROM tblACOELocations
' ORDER BY tblACOELocations.PHYS_LOC_N10;
Me.txtLocID.SetFocus
Me.txtLocID = Me.cboLocation.Recordset.Fields("OLD_LOC_I").Value
Me.cboEmp.Requery
End Sub
Any help is appreciated.