How Do I open youtube in chrome and set focus on the search field?

I am fairly new to Maestro, and trying to set up a macro to open up a youtube in chrome tab and have the cursor on search field.

The problem is that my macro fails to find the search filed.
The search field is the first form in the page, so I used the id of the form (search-form) and the id of the input field (search)


Can anyone guide me how to fix this?

Thank you!

I see two issues with your Macro:

  1. Before the Focus Action is executed you need to make sure the web page is open and loaded.
  1. I think you have the wrong token for the search field. Here is what works for me:
    • image
1 Like

Thank you so much for the reply. Another quick question is the "//" notation to indicate the following expression( [@id='search'] for) is a DOM element?

It is part of the Xpath syntax.

Not sure if this is what you're looking for, but you can press / on the keyboard to select the search bar in youtube.

1 Like