I just lost at least an hour + debugging my code to find out what the problem is. I used an ADODB connection in VBA with parameters. Apparently, if you don't have the Set keyword, the debug output will look as if the parameter has a value, but in fact it is missing. Of course, I knew that I needed Set , but itβs easy to notice when you try to detect a problem.
Problem:
params(1) = cmd.CreateParameter("Email_ID", adInteger, adParamInput, , EmailID)
Corrected Code:
Set params(1) = cmd.CreateParameter("Email_ID", adInteger, adParamInput, , EmailID)
source share