I have created a playable macro that is called in my trading charts. When a certain condition exists, the javaScrpt code shells out and runs the MXE file, and the trading chart window, which has just gained focus from whatever other window I was in, is minimized. The macro ends with the trading chart window minimized.
The problem is that the window I was working in (my trading windows all work by themselves and need not have focus to work), has now lost focus.
Can I write a macro that FIRST gets the CURRENT FOCUSED window (which may not be a trading chart), save it, and then work on the window it was called from to set focus to it, and minmize it, **and then** return focus back to the very FIRST window (which it saved somehow).
is this doable? In other words, the macro ends not when the trading chart is minimized, but when the window that had focus before the trading chart was minimized, is returned focus.