Selecting the matching option


#1

Hello,

I would like to do something as presented in this video below with Kantu:
e.g: paste the text into the input then click on the exact option within the select input.

One problem is the select input work with dynamic ID.

How can I get this thing done?

Thanks in advance.

UPDATE: I decided to remove the video for some reason.


#2

Thanks for the screencast! To select the value from the dynamic dropdown I recommend that you use XClick:

  • XClick | image of text
  • XType | ${KEY_DOWN}${KEY_DOWN}${KEY_DOWN}${KEY_ENTER}
  • or (most flexible) XClick | ocr=text

So in your case the 3rd option with text recognition would be XClick | ocr=Informatique

select%20from%20dropdown


#3

Now it is easy to select a matching option. Nice screencast. Thanks for this.


#4

Thanks for your answer, awesome support!

Just OCR get confuse because there is two “Informatique”. How do I ask OCR to pick the one in the dropdown?

Thanks so much again. Kantu is incredible!


#5

To click the X-th occurrence of a text string, use XClick | ocr=text@pos=X. The occurrences are counted from top left to bottom right.

See here: https://ui.vision/docs/xclick#ocr

Another option would be to restrict the visual search area.


#6

It works, thanks so much!