* some various housekeeping stuff and data collection (done)
* open a form (done)
* fill in fields of the form (done)
* excute a private function stored with the form (???)
(performs updates to other fields in the form)
* have the module WAIT until the form is closed by the user (???)
* resume the module (???)
Here's a code snippet of what I have so far...
Expand|Select|Wrap|Line Numbers
- Do While Not rsCustNum.EOF
- DoCmd.OpenForm "frmInvoicesLookup"
- With [Forms]![frmInvoicesLookup]
- ![filterToEmail].Value = "True"
- ![DateFrom].Value = Date - 8
- ![DateTo].Value = Date
- ![CustomerNumber].Value = rsCustNum!CustomerNumber
- End With
- CustomerNumber
- ' ---
- ' need to set focus to the form in question,
- ' execute the private function,
- ' and wait for the form to close
- ' ---
- rsCustNum.MoveNext
For the 'execute private function' part I could setup code for the form's On Open event that checks for "True" in the filterToEmail field and then calls the private function in question... although I'd rather try to call it from the Module if at all possible.
It's the setting focus to the form and waiting for it to be closed parts that have me stopped.
Thanks!