Autonumber problem in Access database
-
in VB.net 2005 I have problems when i try to insert new record in Access database with Update method.The record has a field Autonumber.And after inserting , in dataset the value of this field is 0, in database is ok.
-
if you are inserting data by dataadaptor and you donot fill dataset after inserting it can be happen . so I think it is better you fill your dataset after per record inserting .
Thank you. The record is inserted in dataset with add(row).But when the dataadapter.update method is executed the record in database is ok , but in dataset the atonumber field is 0. Yes , is possible to fill again the dataset but the application is running on network and if i fill dataset everytime i add new record slow down the app. i know there is a method Select identity but i don't know how to do it.