How do I clear a text box in Visual Studio?
Just use: TextBox1. Clear() It will work fine.
How to clear the text box in selenium C#?
Clear text from textarea with selenium (C#)
As shown clearly in the script for this example, to clear what is written in a text area using the Selenium WebDriver you need to use element. Clear() where element is the text input.