Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

adding a record to a DTC problem...

Status
Not open for further replies.

lehel

Programmer
Jun 18, 2003
5
0
0
US
I've been wrestling with this .addRecord()/.updateRecord() issue for a few days. I've looked at the posts and tried to fix the recordset.asp but didn't help.

What is happenning is I press a button on my form which calls addRecord. This clears the form. I fill in the data and then press an Update button which calls .updateRecord().

The problem is, the record gets added to the table but the record preceding it gets updated with the same data. And the page never returns. It errors like this:

ADODB.Recordset (0x80040E21)
Provider cannot determine the value. Possible reasons: The record was just created, the default value for the field was not available, or the user has not set a new value.


 
Actually, I solved the problem of another record being updated.

My only problem is that after I call addRecord, I call updateRecord which does, in fact, add the data to the table (except some fields are NULL for some reason) and the page still issues the error:


ADODB.Recordset (0x80040E21)
Provider cannot determine the value. Possible reasons: The record was just created, the default value for the field was not available, or the user has not set a new value.
/FTPAdmin/_ScriptLibrary/Recordset.ASP, line 765
 
NM....

I figured out my problem. Somehow, I had a dynamic/server-side cursor recordset and i changed it back to a static/client-side and it fixed the problem...
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top