is a property of the form. the return is a boolean. true or false. the return tells you if the current record is a new entry or not.
is the same thing. it's a property, nothing else. the setting of it (true or false) allows or not, the addition of new records through the interface. for instance, if you put a button on a form and put some new record code behind it, chances are access will error because it violates the "allowadditions" property that is set to "false". does that make sense?
all of these things are just tools at your disposal, as the programmer, that you can use to control user activity.
like I said before, undoes any changes made to the CURRENT record only. it applies to one record at a time, and no more. you can call it a million times if you want. you can also put it in code at any time you want. it doesn't matter. but, to my knowledge, it will only do anything for you if changes have been made to the record.
so if your button takes the user to a new record, but they've changed the one they're on already, you can throw a message box to them and save the changes or not based on what they tell you. you would do so like this:
Code:
on button_click
if me.dirty then
if msgbox("Hey! you changed this rec's data. should I save it for you?", vbyesno) = vbno then
me.undo
'GOTO new rec here
else
'JUST go to new rec
end if
hopefully that is clearer for you, and you can run with it! also please know, that the code I write on this forum I usually write by hand, as examples, so copying it and pasting it verbatim into a vb editor will surely not work for you the first time, unless I get lucky. (I'm no expert, just an experienced guy).