Hello,
I want to have multiple conditions on a recordset based on a query.
It works well with only one condition (Forms!frmalarms![M]) but i also want to add the date condition (>[forms]![frmAlarms]![cmbodate] And <[forms]![frmalarms]![DTM2])
It works fine in the query (see below) but not on my recordset.
Can somewone tell me how to add an additional condition?
Thanks in advance,
Mieke
I want to have multiple conditions on a recordset based on a query.
It works well with only one condition (Forms!frmalarms![M]) but i also want to add the date condition (>[forms]![frmAlarms]![cmbodate] And <[forms]![frmalarms]![DTM2])
It works fine in the query (see below) but not on my recordset.
Code:
Set RS = CurrentDb.OpenRecordset("Select * from dbo_DCEREPORT_INTERRUPTOPERATIONS INNER JOIN dbo_DCEREPORT_MACHINES ON dbo_DCEREPORT_INTERRUPTOPERATIONS.PROCESSRESOURCE_OID = dbo_DCEREPORT_MACHINES.OID where dbo_DCEREPORT_MACHINES.NAME = " & " '" & Forms!frmalarms![M] & "'", dbOpenDynaset)
Can somewone tell me how to add an additional condition?
Thanks in advance,
Mieke
Last edited by a moderator: