WMGetText($id) eq ( ["*agree*" ] or ["*accept*"] )
perlop - X or Y means that if X evaluates to true, X is returned. If X evaluates to false, then if Y evaluates to true, the statement returns Y. Otherwise it returns a false value.
["*agree*"] creates a brand new array reference (perlref). Add this to the previous paragraph, and you are comparing one of two brand new array references or false (which will simplify to just the new arrayref ["*agree*"]) to the results of WMGetText($id) to see if they are equal in a string comparison. Very unlikely to return the results you want.
Update: reduce part after eq to just arrayref.
--MidLifeXis
In reply to Re^3: Gui Automation using guitest
by MidLifeXis
in thread Gui Automation using guitest
by shayak
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |