Hi
I have two forms in my database.
frmStart after the user enters their name and call media they press the new call button. This code is executed with the new call button is pressed
DoCmd.OpenForm "frmMain", , , , acFormAdd
DoCmd.GoToRecord , , acNewRec
The second form then opens and the record source of this second form is tblcustomers. On the form frmMain I have a textbox called IDNumber which is linked to the ID field of the table tblcustomers. The user can press an abort button without entering any information into the form due to this I need a way of saving the current record without creating a new record as I would like to use the value IDNumber and store this in another table.
Basically IDNumber is not shown onscreen until I force access to save the record (using Me.Dirty = False in the onclick event of the abort button) - but using this code creates another record in the tblcustomers table.
Is there anyway of saving the current record without moving on to the next record?
Thanks
Are the two forms open all the time?
You may save the ID of the main form, and when aborting, use that saved ID to go back to the required record.
To abort use Undo command, instead of dirty.