Forum Discussion
tristaanogre
15 years agoEsteemed Contributor
Hard to do a "code sample" for a keyword test that is a visual test. The "Label" statement and "Go To Label" statements are for creating keyword tests, not for script code.
As for the code you have, that looks like the best thing. You're looking to see if the form exists. If it does, log a warning, and break out of the loop.
As a suggestion, I'd change your if statement to, instead of WaitProperty, do something like
The reason being is that if FinishScreenFinishButton doesn't exist, it doesn't make any sense to check properties on a non-existent object.
As for the code you have, that looks like the best thing. You're looking to see if the form exists. If it does, log a warning, and break out of the loop.
As a suggestion, I'd change your if statement to, instead of WaitProperty, do something like
if(!Aliases["MSIEXEC"]["BaseWindow"]["WaitAliasChild"]("FinishScreenFinishButton", 15000).Exists) The reason being is that if FinishScreenFinishButton doesn't exist, it doesn't make any sense to check properties on a non-existent object.