Subform problem

libby32

Registered User.
Local time
Today, 23:08
Joined
Mar 6, 2003
Messages
42
I hava form / subform combination that is opened from another form. The main form is opened with specific data that the user chooses and then they need to add the subform data. The people who will use the program probably have never even used a computer before. The problem is if they keep hitting the tab button on the subform, it automatically adds the subform data.

How can I prevent the subform record from being added until someone clicks a button, a messagebox pops up and says "Are you sure you want to add this information?" and the user needs to say yes before the data is added.......
 
Use the beforeupdate event of the subform to ask the necessary questions prior to the record being saved.

If Msgbox("Save Now?",vbYesNo + vbQuestion,"Confirmation Required") = vbNo then
'cancel save here
Cancel = True
End if

Do a search on this forum for BeforeUpdate for more help.
 

Users who are viewing this thread

Back
Top Bottom