In UFT 15.0.2 : How to write or passing partials value in AI script.
♥ 0 |
For Example : IntPrice = AIUtil.FindTextBlock(“Your Price: $1,533.00”).GetText. ‘Your Price ‘ is static but amount value is changed. so here how to write dynamic script by using static value ( Your Price).
Marked as spam
|
Private answer
You should be able to remove the number, and UFT's AI will recognize the object anyway. Try:
and see if it works. If there is more than one object on the screen with the same text, it may be more difficult to isolate the one you want. You may need to use some of the tips and tricks listed here: Improve AI-based test object identification (microfocus.com), most notably the "Identifying objects by relative location" section my be particularly helpful. There are some instances where you need to mix traditional objects with AI objects in your test. In this case, you can simply go into the object properties and make the appropriate property a regular expression. Here's some information on doing that: Marked as spam
|