Unable to click on ag - grid cell


having issue in performing click operation on ag- grid cell. pls find attached screenshot.
I have already tried executeJavaScript(“arguments[0].click()”, Arrays.asList(element)) , but nothing worked.

Thanks in advance!

executeJavaScript(“arguments[0].click()”, Arrays.asList(element))

Why the Arrays.asList() call? You can only every click on one element at a time. Also, what locator was used to find your element?

I’m using xPath - //div[@id=‘myGrid Team_Member_View’]/div[2]/div/div[6]/div/div/div[2]/div/div[2]/div[2]/div

Can u pls help me here

This is a really fragile xpath. You should almost never rely on direct xpaths like this, as element positions can/do change relatively frequently. You should use relative xpaths like this one:

//div[@role='option' and normalize-space()='Team Member']

Also, do not use Arrays.asList(element) like you did in your OP. Just do this:

executeJavaScript(“arguments[0].click()”, element)