Forum Discussion

Audrey's avatar
Occasional Contributor
3 years ago

OCR Action-Object does not exist

Hi, I am using OCR action to click on the element in a dropdown list depending on what users type in. I set an event control where if there is OnLogErrror then it will move down. When i run it, if the element is not visible, then it will move down, however, after the element becomes visible, the OCR click action returns me "Object Does not exist" error instead of clicking on it. May i know how to resolve this?

4 Replies

  • Hi Audrey 


    In the test log, are either the parent or OCR object visible in the screenshot?

    OCR actions are pretty fast, the screen snippet is taken instantly before it's sent through the OCR API, so you may need to add a one-second delay or a Wait operation to allow the element to appear for the OCR action to scan it. 


    Hope this helps

    • Audrey's avatar
      Occasional Contributor

      Hi mikef 

      i try to put delay in my event control which means if the object is not found, it will go down and delay for 2 seconds before it perform OCR click again. However, it returns me the same error. The test log still recognizes only the objects before scrolling down.


      • mikef's avatar
        Hi, No, you need to put the delay right before the OCR point, in order to give the application under test time to catch up and get in the right state for the OCR snap. Can you try that? Thanks