ADO: .update command not mandatory for each record?

T

The Dude

Hello :)

Due to a variable name error, I have noticed that records can still be added
although there is no .update command in the code - except for the last record.

Hence my question : Can I loop and add records with .addnew and only use
..update command at the end of the loop (to add the last one)?
It seems to be working, but is it a problem if I do it?

Thanks
T_D
 
R

RoyVidar

The said:
Hello :)

Due to a variable name error, I have noticed that records can still
be added although there is no .update command in the code - except
for the last record.

Hence my question : Can I loop and add records with .addnew and only
use .update command at the end of the loop (to add the last one)?
It seems to be working, but is it a problem if I do it?

Thanks
T_D

Yes.

If you move from the record you're editing, ADO will save the changes,
without having to call the .update method.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top