in reply to Re^2: Gui Automation using guitest
in thread Gui Automation using guitest
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
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: Gui Automation using guitest
by shayak (Acolyte) on Feb 16, 2011 at 05:40 UTC | |
by Anonymous Monk on Feb 16, 2011 at 10:00 UTC | |
by MidLifeXis (Monsignor) on Feb 16, 2011 at 14:02 UTC | |
by shayak (Acolyte) on Feb 17, 2011 at 12:26 UTC |