Can't undo?

N

Nad

Hi All!
I have a form with subform on it to add new record. I put a command button
"Exit Without Save" and i wrote 'me.undo' on it.But this is not working when
i click this button, it is not undo the changes.

Regards
 
A

Allen Browne

Chances are the record is already saved before the button's click event is
executed.

Is the button on the main form or in the subform? If you put it in the main
form, Access completes whatever is happening in the subform (e.g. saving the
record) *before* it allows the focus to move back to the main form, so this
approach cannot possibly work.

There is an Undo button on the toolbar. Could you use that one instead of
the one on the main form?

Alternatively, pressing Esc twice is better than an undo button on your
form. This undoes the current field (first Esc) and then the record (second
Esc), regardless of what's happening at the time.
 
N

Nad

Thanks for reply.
The button is on the Main form. I converted this to accde file so every
thing is disable. User can not use Undo/redo button.I need this botton on my
form and also not all user is aware of using Esc key once or twice.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top