How to select values in empty rows only

everyone has access to different sites and it looks like the following for two different people:

Person 1:

Person 2:

Now when I click on the + sign (shown below), it opens an empty place when when I click I can assign a new site to that person.

And if you click under the “customer” for example then it opens the dropdown

Now, because everyone has access to different sites therefore this empty place appears at different rows for each user (always gets added at the end) and I am unable to do any automation because imagine, if I write a script for person 2, who gets the empty place at row 2 and I am putting new values there from the dropdown then for person 1 also, the row number 2 will get over-written.

Is there any way, I can fill only this empty row and ignore others that already filled?

1 Like
  1. You should read the HTML source of the target web page.
  2. You should find how to identify an empty row there. You should define the condition how a row is regarded as empty.
  3. You should learn XPath expression or CSS Selector to express the condition you defined.

In order to read the HTML source of your target page, you would want to learn how to use Chrome DevTools.

In order to study XPath, read Guru99: XPath in Selenium: How to Find & Write Text, Contains, OR, AND

1 Like

Thank you for the guidance @kazurayam