Page 1 of 1

Form keep adding new record when modifying an entry

Posted: Wed Aug 02, 2017 3:21 pm
by Ablaknyitókilincs
Hey there!

So I just made a form good enough for my needs, and it contains a mainform, which is doing the name entry, and a save button, everything else in sub forms, opening from each other. (need this because the next entry is filtering from the previous entered data).

Basically, this will be an "Enter data only" form, it can not show already entered ones. The working is simple: enter name-> enter customer -> enter location (of the customer) etc.etc. all by list boxes.
Working fine, entering the right data in the right fields so kinda good.

But there is a problem that I can't even understand why even happening.

When I select something, and save the data (refresh button in the subform), it goes well. But (anywhere in the form, even in the first, or last data saved) if i go back to the previous field (basically i'm already in the next sub-form by clicking the "save data" button, and going back to the prev. sub-form (or main form)), and change the entered data from the list it changing the data entered in the table noicly. (and this is how it supposed to work).
BUT!!! when I go to the next list (or subform) to change that too (example: changed the customer, and they have different locations, so need to change that too), after the save button, it creates a new record entry (in the table), containing only that one data entered (location id for example).
I have an "entry ID" named field, which is showing the current entry id, and when this bug or something happens, it shows the original ID, and not the newly created one (with the 1 data only).

First it gave me a bunch of errors, but after I put everything (literally) to "input required = no" it does this. (before changed them it gave me error like this "trying to enter NULL into a non-nullable column")

Any ideas?

Re: Form keep adding new record when modifying an entry

Posted: Wed Aug 02, 2017 9:47 pm
by MTP
Can you upload your file, or an example file with any private information removed? If you press the "PostReply" button, under the text box there is an "Upload attachment" form.

Re: Form keep adding new record when modifying an entry

Posted: Thu Aug 03, 2017 2:59 pm
by Ablaknyitókilincs
I tried to delete the confidential records, but I can't, because there are too many connections (PK-FK) etc. :\