Hi everyone
I have an entering form that allow me to insert record into a table.
On that form I have a field named "addedby" which picks the name of the current logged in userid as default value when entering new record.
I have the following code that allow the above to work:
Private Sub Form_Current ()
If Me.New record = True Then
Me!Addedby = Forms!frm_MainMenu.Txt UserId
End If
End Sub
However, when a new record entry is cancelled (clik on add new button and cancel entry), new row is created in the table as if the entry process was not cancelled.
Meaning if we have to cancel 1000 record entry, we are going to end up having 1000 rows created with all fields being blank, except the ID.
Note that my table has the field "Id" as Auto number which is the primary.
Can anyone help me get rid of this problem.