I have an error message...
"Compile error:
ByRef argument type mismatch"
When the error pops up the variable "vMisc" is selected...
I didn't receive the error message yesterday...haven't changed anything in the code.
Code:
Private Sub cmdUpdateData_Click()
Dim vAuto, vFWD, vMisc, vOnTimeExec As Double
Dim i As Integer
i = 1
vAuto = DLookup("PctAuto", "qryEmailPercents_Month", "[RecordID] = " & i & "")
vFWD = DLookup("PctFwd", "qryEmailPercents_Month", "[RecordID] = " & i & "")
vMisc = DLookup("PctMisc", "qryEmailPercents_Month", "[RecordID] = " & i & "")
vOnTimeExec = DLookup("PctCompleted", "qryOnTimeExecution", "[RecordID] = " & i & "")
Call funEmailData(vAuto, vFWD, vMisc)
End Sub
Function funEmailData(vPctAuto, vPctFwd, vPctMisc As Double)
Dim mySQL, vMetricName, vFiscMonth As String
Dim db As DAO.Database
Dim rs As DAO.Recordset
'.........code
End Function