Take the 2-minute tour ×
Software Quality Assurance & Testing Stack Exchange is a question and answer site for software quality control experts, automation engineers, and software testers. It's 100% free, no registration required.

I am working to write some Selenium WebDriver scripts that work with Telerik RadEditor controls. I can successfully enter content into the RadEditor in the following way with C#:

Driver.FindElement(By.Id("Id_Of_RadEditor_Iframe")).SendKeys("Hello World!");

But I have not been able to find a way to clear the existing content of the RadEditor. If I attempt the following:

Driver.FindElement(By.Id("Id_Of_RadEditor_Iframe")).Clear();

I will get this error:

OpenQA.Selenium.InvalidElementStateException: invalid element state:
Element must be user-editable in order to clear it.

Does anyone know a way to clear the existing content from the RadEditor?

P.S. Does anyone think this may be a bug in Selenium WebDriver? Since I know the IFrame is editable since I can successfully perform SendKeys(). This seems to make the error incorrect.

Kerry

share|improve this question
    
See this answer from StackOverflow. –  Brandon Jun 13 at 20:04

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.