Keeping layout in focus
I have a layout which is getting a little lost and needs to keep focus until the user makes a decision. Is there anyway to keep a layout in focus on top of other layouts?
For two examples of what Nick is suggesting download the Known Bugs List database (click the blue download button). You can check the script attached to Find, Modify Find, Edit or New and see how they do this.
Note that this technique as implemented in this file requires buttons or scripts that use Halt Script to terminate the Pause/Resume as the scripts in this file enclose this step in an infinite loop.
I presume you have a script that opens the layout in a New Window, in which case, perhaps try adding a Pause/Resume Script [Indefinitely] step at the end of the script. This will keep the window on top until the user clicks the "Continue" button in the Status Area or presses Enter.
Cheers guys, got it working using the example given.
Anyone trying this, the example uses a script parameter to close the window - don't forget to pass it!
Actually, the script parameter has nothing do to with closing the window. It just enables two different buttons to use the same script to present the floating window in slightly different ways based on the parameter passed. Thus clicking Find clears the Global fields on its search layout and clicking Modify Find does not.
The main detail to watch out for is that since user aborts aren't allowed. Any action that closes the window requires a halt script step to terminate the infinite loop in the script. Failure to do this can result in being trapped in a loop with a Force Quit an possible file damage as the only way out.
I suddenly remembered what "parameter" is being passed that affects window closing. In one of the scripts that close the floating window, I pass the name of the window to be closed as a script parameter. This is not strictly necessary for this technique.
Retrieving data ...