Hello Simon,
Are you using TS 2.0 or 2.01? I have tried to replicate the problem that you have described, but I am not able to. Does this happen for all VIs that get called or just some?
There are two ways that a VI front panel is shown during a TestStand execution: 1) In the Specify Module dialog box, "Show VI Front Panel When Called" is enabled or 2) In the VI properties, under window appearance, in the customize options, "Show Front Panel When Called" is enabled. But when I try both methods, TestStand still becomes the active window after the VI completes (even if it does not close).
Of course, as long as the VI is running, it is the active window. You can change that programmatically within the VI by using VI Server to access the properties of the VI itself. Place down a property node. Right-click on it and navigate to "Select Class >> VI Server >> VI". Then right-click on the property and navigate to "Properties >> Front Panel Window >> State". This property allows you to programmatically minimize the front panel of the VI.
Regards,
Aaron B.
National Instruments