selenium-powershell icon indicating copy to clipboard operation
selenium-powershell copied to clipboard

.Clear() Equivalent?

Open ASAJacob opened this issue 3 years ago • 1 comments

Hello. In python you can clear a text field by calling .clear() on the element. Is there an equivalent cmdlet in the module or different way to accomplish this? I tried to achieve by running Send-SeKeys -Element $search_box -Keys ([OpenQA.Selenium.Keys]::Clear) but it doesn't seem to work as expected.

ASAJacob avatar May 31 '22 20:05 ASAJacob

Hello, As a workaround you can use: $search_box.Clear()

BogdanIstrate avatar Jun 04 '22 06:06 BogdanIstrate