I'm writing a VB program to move data from Access to a file in a specific format. I keep encountering an error that I can't seem to figure out. The error is "No value given for one or more required parameters". I get this error for the following line of code:
Set MyBudgetSet = MyConn.Execute("Select * from BudgetItem where ProjectNumber = " & Chr(145) & strProject & Chr(146))
The whole program is attached. Any and all help is appreciated. I'm stumped.
FWIW, 145 & 146 are a good way to circumvent the problems created by passing
word quotes or apostrophes into database objects, but not for delimiting string
values.
Assuming ProjectNumber is a char/varchar datatype, only ASCII characters 34 and 39
can act as string delimiters, otherwise you should omit them with a numeric datatype.
Thanks, I changed it from chr(145) and chr(146) to chr(39), but I'm still encountering the same error with the same line of code. I've made other changes to my program and have attached it. Any idea why i'm getting the error?