Hi there,

I have a form that adds a Customer to a database. I had set the cust_id in the Ms Access as an Autonumber. and when I open the vb form, i wrote a code that will set the textbox of the cust_id as the count of the records + 1. That is displayed correctly.

my problem is this. When I click on the button save i have the following code attached

me.databinding(dataset11, "Customer").addnew()

it's telling me that since the cust_id is a primary number, it's doesn't allow it to be null. Now i'm generating that number as i specified in the first paragraph.

any help?


As I understand it ur not supposed to be inserting anything in the auto number field, Access should take care of that automaticaly.