Hello hien.phan. Thanks for using ZAPTEST.
For your task there is another solution. Simply create an object on the view and call it (for example) “TEXT”. It has “OCR Single” recognition type and you better switch it to “OCR Partial”.
Than in the script code you can assign text value to this object using SetProperty method. And then use Exist method to check if this text presented on the screen. It will look like:
[b][i]Application(“Application”).View(“View”).Object(“TEXT”).SetProperty “Text”,”Here is your text to validate”
Application(“Application”).View(“View”).Object(“TEXT”).Exist[/i][/b]
Hope that helps.
Thanks.
ZAPTEST Team.