Re: What is the difference between win_activate() and set_window()?
From the TSL help files that are easily obtained by clicking "F1" while in a script in WinRunner....
The win_activate function makes the specified window the active window by bringing it into focus and raising it to the top of the display (equivalent to clicking on the window banner). All subsequent input is submitted to this window.
<font size="2" face="Verdana, Arial, Helvetica">
The set_window function directs input to the correct application window. This directs the GUI map to this window. Note that the timeout test option or configuration parameter is in effect even if the time parameter is not specified.
During recording, a set_window statement is automatically generated whenever you perform an operation on a control that belongs to a window different from the previously active window. When the test is run, the function brings up the specified window. All subsequent TSL statements are performed on this window, until the next set_window statement is interpreted.
The set_window function also sets the scope for object identification in the GUI map. All objects within the window specified by the function are then classified according to category. During a test run, the search for an object is performed within the scope of the window in which it was defined.
<font size="2" face="Verdana, Arial, Helvetica">One brings the window to the top of focus, the other doesn't, but both direct follwing input from WinRunner to thie window.
Insanity: doing the same thing over and over again and expecting different results