D
Del
What is wrong with this code. I get a compile error on "!cboCycle" that says
"Method or data member not found". If I change !cboCycle to !cboDept I get
the same error but !cboDept compiled earlier in this code.
DoCmd.RunSQL "UPDATE tblEquip INNER JOIN tblPMCurrentTasks ON
tblEquip.EquipID=tblPMCurrentTasks.EquipID " & _
"Set tblPMCurrentTasks.[PerformedBy]='" & Me.txtPerformedBy &
"',tblPMCurrentTasks.[Done]= -1, " & _
"tblPMCurrentTasks.[DateDone]=#" & Date & "#" & _
"Where tblEquip.[Dept]='" & Forms!frmPM!cboDept & "' And
tblPMCurrentTasks.[PMCycle]='" & _
Forms!frmPM!cboCycle & "' And tblEquip.[Line]='" & Me.cboLine &
"' And tblEquip.[EquipID]= " & _
Forms!frmPM!txtEquipID & "and tblPMCurrentTasks.[Done]<>-1;"
"Method or data member not found". If I change !cboCycle to !cboDept I get
the same error but !cboDept compiled earlier in this code.
DoCmd.RunSQL "UPDATE tblEquip INNER JOIN tblPMCurrentTasks ON
tblEquip.EquipID=tblPMCurrentTasks.EquipID " & _
"Set tblPMCurrentTasks.[PerformedBy]='" & Me.txtPerformedBy &
"',tblPMCurrentTasks.[Done]= -1, " & _
"tblPMCurrentTasks.[DateDone]=#" & Date & "#" & _
"Where tblEquip.[Dept]='" & Forms!frmPM!cboDept & "' And
tblPMCurrentTasks.[PMCycle]='" & _
Forms!frmPM!cboCycle & "' And tblEquip.[Line]='" & Me.cboLine &
"' And tblEquip.[EquipID]= " & _
Forms!frmPM!txtEquipID & "and tblPMCurrentTasks.[Done]<>-1;"