TonC
02-09-2016, 01:48 AM
Hello,:(
I've got a table named "tblRelaties". In that table there two fields:
rel_id = autonumbering and Primary key
Relatienaam = just text
When I want to filter on a relationname (Relatienaam), in some cases the form shows me 3 or more relations, while I'am looking for just one relation.
I presume it has somthing to do with the autonumbering, because there is a relation with the number 7, but also relations with the numbers 87 and 27.
In my query, in the field named "Relatie" there is this criteria;
Like [Forms]![frmMagazijn1]![cmbRelatie]
The criteria
Like [Forms]![frmMagazijn1]![cmbRelatie] & "*" did not work
The criteria
Like "*" & [Forms]![frmMagazijn1]![cmbRelatie] & "*" did not work
And my VBA code is: (a combobox on my mainform named "cmdRelatie")
Private Sub cmbRelatie_AfterUpdate()
Me.subfrmMagazijn1.Requery
End Sub
What goes wrong? Can someone help me?
If you need further information, please contact me.
Many thanks in anticipation
I've got a table named "tblRelaties". In that table there two fields:
rel_id = autonumbering and Primary key
Relatienaam = just text
When I want to filter on a relationname (Relatienaam), in some cases the form shows me 3 or more relations, while I'am looking for just one relation.
I presume it has somthing to do with the autonumbering, because there is a relation with the number 7, but also relations with the numbers 87 and 27.
In my query, in the field named "Relatie" there is this criteria;
Like [Forms]![frmMagazijn1]![cmbRelatie]
The criteria
Like [Forms]![frmMagazijn1]![cmbRelatie] & "*" did not work
The criteria
Like "*" & [Forms]![frmMagazijn1]![cmbRelatie] & "*" did not work
And my VBA code is: (a combobox on my mainform named "cmdRelatie")
Private Sub cmbRelatie_AfterUpdate()
Me.subfrmMagazijn1.Requery
End Sub
What goes wrong? Can someone help me?
If you need further information, please contact me.
Many thanks in anticipation