Hello - I'm hoping someone will be able to answer the following question I have regarding a form I am working on. I have been trying for days, with varying success to get this to work - I've tried everything I can think of but I'm missing something.... Here is a description of what I'm working on and what I would like it to do:
I have a main form which displays information from a query(no data input here)with a subform where users enter data in up to 12 fields (there is code which opens the form with the exact number of fields specified by the user). The main form contains a command button which closes both forms and opens another.
The fields in the subform must contain data. I know there are a variety of ways to validate data but what I want to do is put this action into the command button. I want to click the command button, validate for a "" condition in the subfields, send a message if data is missing and cancel the closing of the form. So far I can accomplish all but one thing using a macro. I can't stop the button from closing the form before the user has had a chance to fill in the data.. I'm not sure what i should do here...any suggestions?
Thank you!
I have a main form which displays information from a query(no data input here)with a subform where users enter data in up to 12 fields (there is code which opens the form with the exact number of fields specified by the user). The main form contains a command button which closes both forms and opens another.
The fields in the subform must contain data. I know there are a variety of ways to validate data but what I want to do is put this action into the command button. I want to click the command button, validate for a "" condition in the subfields, send a message if data is missing and cancel the closing of the form. So far I can accomplish all but one thing using a macro. I can't stop the button from closing the form before the user has had a chance to fill in the data.. I'm not sure what i should do here...any suggestions?
Thank you!