Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

me.undo help with subform

Status
Not open for further replies.

rooterr

Technical User
May 15, 2001
21
0
0
US
I need help understanding me.undo. I have a form where you enter projects and responsible persons. The subform for this holds all the required steps to complete said project. Some people have started filling out the form and before entering the steps just get out. I need to be able to undo their entries in the main form if steps in the subform is null. I believe the me.undo is what I need to use, but don't know how it works, or where to put it.

Any help would be appreciated
RT
 
Undo will cancel all changes made to a form prior to its updating the underlying record source. Most people associate it with a cancel button that once pressed does a me.undo which will reset the forms values to what they were previously.

If you are using a sub form within a main form you must keep in mind that if you move from the sub form to any area outside of the sub form your sub form will attempt to update its underlying record set so that a me.undo issued from the main form is to late to cancel the update of a sub form.

You may want to use the sub forms before update event to make sure they have properly input all the data your sub form must have and if not simply set cancel = true in that event which will cancel the update request.

You can use the same concept on the main form as well. You can either cancel the update from the forms before update event or provide a cancel button on your form(s) which would do a me.undo using the onclick event of the cancel button.
Robert Berman
Data Base consultant
Vulcan Software Services
thornmastr@yahoo.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top