Private Sub Form_AfterUpdate()
Me.Parent.txtOjectDefinition = Me.txtQuantity & " " & Me.cboObject.Column(1)
End Sub
Private Sub FormAfterUpdate()
Dim rs As DAO.Recordset
Dim Definitions As String
Set rs = Me.RecordsetClone
While Not rs.EOF
If Definitions <> "" Then
Definitions = Definitions & " + "
End If
Definitions = Definitions & rs!txtQuantity.Value & " " & DLookup("ObjectName", "Objects", "ObjectID = " rs!Object.Value & "")
Wend
If Definitions <> ""
Me.Parent.txtOjectDefinition.Value = Definitions
Else
Me.Parent.txtOjectDefinition.Value = Null
End If
rs.Close
End Sub
where Objects is a table holding your descriptions.
Private Sub Command491_Click()
Dim rs As DAO.Recordset
Dim ProofDefinition As String
Set rs = Me.RecordsetClone
While Not rs.EOF
If Me.txtProofDefinition <> "" Then
Me.txtProofDefinition = Me.txtProofDefinition & " + "
End If
Me.txtProofDefinition = Me.txtProofDefinition & rs!txtQuantity.Value & " " & DLookup("ProofType", "tblEstimateProofs", "EstimateID = rs!EstimateID.Value")
Wend
If Me.txtProofDefinition <> "" Then
Me.Parent.Me.txtProofDefinition.Value = Me.txtProofDefinition
Else
Me.Parent.Me.txtProofDefinition.Value = Null
End If
rs.Close
End Sub
Me.txtProofDefinition = Me.txtProofDefinition & rs!txtQuantity.Value & " " & DLookup("ProofType", "tblEstimateProofs", "EstimateID = " & rs!EstimateID.Value & "")
Open in new window
But you will get into trouble if you try to modify the selection(s).