SHORT VERSION:
When this particular form button is clicked, I would like it to find the most recently opened form (or the one that is currently visible, or last had focus, or 'in front') and close it. IS THERE CODE??
LONG VERSION:
I have a subform (sfNavbar) that appears on all forms which allow it. It contains navbar kind of stuff and a DONE button. With Continuous Forms I must use sfNavbar as a fixed modal window instead of a subform.
When the DONE button is pressed I can determine whether it is a subform by its tag, and if so close the parent form.
When it's a modal window, I want it to find the most recently opened form (or the one that is currently visible, or last had focus, or 'in front') and close it. Other forms may be open behind it.
I can instruct the code to determine whether a form is currently open with acSysCmdGetObjectState, but alas, that's not enough.
Is it possible to fix a background constant/variable that changes as different forms are opened or focused upon?
When this particular form button is clicked, I would like it to find the most recently opened form (or the one that is currently visible, or last had focus, or 'in front') and close it. IS THERE CODE??
LONG VERSION:
I have a subform (sfNavbar) that appears on all forms which allow it. It contains navbar kind of stuff and a DONE button. With Continuous Forms I must use sfNavbar as a fixed modal window instead of a subform.
When the DONE button is pressed I can determine whether it is a subform by its tag, and if so close the parent form.
When it's a modal window, I want it to find the most recently opened form (or the one that is currently visible, or last had focus, or 'in front') and close it. Other forms may be open behind it.
I can instruct the code to determine whether a form is currently open with acSysCmdGetObjectState, but alas, that's not enough.
Is it possible to fix a background constant/variable that changes as different forms are opened or focused upon?