2004-12-25, 08:23 AM
Okay, after banging my head against a brick wall for the last 3 hours, I finally gave up and just coded my Insert Statement manually. Here's the question.
Can somebody post some working OleDB code for .NET that actually sets the values for a Prepared Statement's Parameters. Should have been as simple as defining the variables in the Insert string, setting the variables, and executing the prepare. However, the Parm.Value never takes, it is always Null.
Anyway, I'd rather use the Prepare than hard coding the insert string, because right now it only works on MSDE or a database that supports the CAST statement (Access doesn't).
Can somebody post some working OleDB code for .NET that actually sets the values for a Prepared Statement's Parameters. Should have been as simple as defining the variables in the Insert string, setting the variables, and executing the prepare. However, the Parm.Value never takes, it is always Null.
Anyway, I'd rather use the Prepare than hard coding the insert string, because right now it only works on MSDE or a database that supports the CAST statement (Access doesn't).