Hello everyone,
I hope someone will have an answer for the question that is bugging me.
When I open Sales form and go to NewRecord in order to enter new sale, SaleID field (which is also AutoNumber field and a PK for tblSales) is blank. It says (New), and that is OK since nothing is entered still. When I select a customer from a listbox, i have onClick event that correctly enters the CustomerID into tblSales. If I check tblSales, new record is created, also the AutoNumber ID, but the form still holds (New). I have tried anything I can think of, but I cannot get it to show this field (which I need later on the same form to enter purchased products in order to relate SaleID with purchased products). I have tried refreshing the form, various events, but nothing.
In earlier variant of the mdb, ComboBox served as a customer selection, and everything worked nicely (on AfterUpdate event).
Now, the only way I see is that after customer selection, I find the last row and use that number to connect with purchased products. But I cannot understand why AutoNumber field is not shown.
Thanks to all.
I hope someone will have an answer for the question that is bugging me.
When I open Sales form and go to NewRecord in order to enter new sale, SaleID field (which is also AutoNumber field and a PK for tblSales) is blank. It says (New), and that is OK since nothing is entered still. When I select a customer from a listbox, i have onClick event that correctly enters the CustomerID into tblSales. If I check tblSales, new record is created, also the AutoNumber ID, but the form still holds (New). I have tried anything I can think of, but I cannot get it to show this field (which I need later on the same form to enter purchased products in order to relate SaleID with purchased products). I have tried refreshing the form, various events, but nothing.
In earlier variant of the mdb, ComboBox served as a customer selection, and everything worked nicely (on AfterUpdate event).
Now, the only way I see is that after customer selection, I find the last row and use that number to connect with purchased products. But I cannot understand why AutoNumber field is not shown.
Thanks to all.