Page 1 of 1

Ranorex path with regular expression problem

Posted: Wed Sep 09, 2009 3:39 pm
by lingzhou
I have a scrollbar object in my project repository, the path is
"list/scrollbar[@type='ScrollBar' and @fulltype='fl.controls::ScrollBar' and @maxvalue='5300']/button[3]"

almost every build, the maxvalue changes. Is there anyway that I can put a wildcard character on this object so I don't have to change it everytime before I run it? I have tried those but all failed

"list/scrollbar[@type='ScrollBar' and @fulltype='fl.controls::ScrollBar' and @maxvalue='*']/button[3]"

"list/*/button[3]"

"list/scrollbar[@type='ScrollBar' and @fulltype='fl.controls::ScrollBar']/button[3]"

Can anyone give me suggestions on how to use regular expression here?

Re: Ranorex path with regular expression problem

Posted: Wed Sep 09, 2009 6:28 pm
by Support Team
Wildcards are not regular expressions! That means "*" is not a regular expressions for "match everything".

Please read the regular expression documentation in the Ranorex User Guide and/or on MSDN:
http://www.ranorex.com/support/user-gui ... html#c2463
http://msdn.microsoft.com/en-us/library/az24scfc.aspx

I believe you meant ".*" which matches any character zero or more time (= "match everything").

Regards,
Alex
Ranorex Support Team

Re: Ranorex path with regular expression problem

Posted: Wed Sep 09, 2009 10:09 pm
by lingzhou
thanks for the help, Alex.