I am trying to focus on an element to make this element in the center of the screen or way from the top to be above the middle. This is what I did
.FindElementById("toBePaid[" & r - 1 & "]").ExecuteScript "this.scrollIntoView(true); window.scrollBy(0, -(window.innerHeight - this.clientHeight)-150);"
But I couldn't see the element as it is at the top-most of the screen of the website.
I have tried too
.FindElementById("toBePaid[" & r - 1 & "]").ScrollIntoView True
But the same problem is still there.