UpdateBatch (1 Viewer)

muratas2

Registered User.
Local time
Today, 13:48
Joined
Jan 18, 2000
Messages
16
Hi,

I need to update several records of a recordset depending on the values on a form. I open the Recordset and apply Seek method to find the value I want. When I find it I update the record setting a value to a field. Then when I apply Seek method again and try to set another value to that field I receive an error "The number of rows with pending changes has exceeded the set limit" If I wasn't received it I was gonna run recordset.UpdateBatch method. Should I indicate the number of records to be updated at the beginning somehow?

Where am I wrong?

Thanx in advance

Murat
 

Travis

Registered User.
Local time
Today, 05:48
Joined
Dec 17, 1999
Messages
1,332
After your seek has found and you have changed the data use the .Update command to save the changes. Then make sure you return to the First Record before your next seek. (Just to make sure you iterate all records.)
 

muratas2

Registered User.
Local time
Today, 13:48
Joined
Jan 18, 2000
Messages
16
Thanks Travis,

I tried what you wrote, still in trouble! By the way, I'm using ADO.

Thanks again

murat
 

Users who are viewing this thread

Top Bottom