R
Richard
I am using Access 2000 I complied the below code and recived the following
error: Compile error: Variable not defined. If I compile with just Option
Compare Database I get no error, But if use Option Compare Database Option
Explicit I recive
Compile error: Variable not defined.
**********************************************************
Private Sub cmdSearch_Click()
On Error GoTo Err_cmdSearch_Click
strSQL = "UPDATE tblWarehouse " & _
"SET Signature = '" & Me.txtSignature & _
"' WHERE Signature is Null AND [Date]=#" & _
Me.txtDate & "# AND [School]='" & Me.txtSchool & _
"' AND Driver='" & Me.txtdriver & "'"
DoCmd.RunSQL strSQL
Exit_cmdSearch_Click:
Exit Sub
Err_cmdSearch_Click:
MsgBox " Please Try Again! "
Resume Exit_cmdSearch_Click
End Sub
************************************************************
It highlight in yellow on this.. strSQL =
any ideas? the rest of the code compiles with no problems.
error: Compile error: Variable not defined. If I compile with just Option
Compare Database I get no error, But if use Option Compare Database Option
Explicit I recive
Compile error: Variable not defined.
**********************************************************
Private Sub cmdSearch_Click()
On Error GoTo Err_cmdSearch_Click
strSQL = "UPDATE tblWarehouse " & _
"SET Signature = '" & Me.txtSignature & _
"' WHERE Signature is Null AND [Date]=#" & _
Me.txtDate & "# AND [School]='" & Me.txtSchool & _
"' AND Driver='" & Me.txtdriver & "'"
DoCmd.RunSQL strSQL
Exit_cmdSearch_Click:
Exit Sub
Err_cmdSearch_Click:
MsgBox " Please Try Again! "
Resume Exit_cmdSearch_Click
End Sub
************************************************************
It highlight in yellow on this.. strSQL =
any ideas? the rest of the code compiles with no problems.