Hi Oscar,

Thank you for responding.

Isn't that what I am doing already?  I am not fimiliar with send_keys other
than typing out text.

Thank you,
Joe
On Sep 25, 2012 2:04 PM, "Oscar Rieken" <[email protected]> wrote:

> why not send control A and then delete
>
> On Tue, Sep 25, 2012 at 2:04 PM, Joe Fl <[email protected]> wrote:
>
>> The problem I am having is when this line of code is
>> executed @browser.frame(:class=>/gwt-**RichTextArea/).click
>> in Chrome the cursor is place at the end of the string and in Firefox the
>> cursor ends up in front of the string.
>>
>> So the backspace isn't deleting the current text.
>>
>>
>> Thank you and any help would be greatly appreciate.
>> Joe
>>
>>
>> On Tuesday, September 25, 2012 1:09:49 PM UTC-4, Joe Fl wrote:
>>>
>>> Hi everyone,
>>>
>>> I need to know if there is a better way to delete a string of text from
>>> a RichTextArea.
>>>
>>>
>>> Currently I handle it this way:
>>> @browser.frame(:class=>/gwt-**RichTextArea/).click
>>>  # Erase old comment
>>> for rte in 
>>> [email protected](:class=>/**gwt-RichTextArea/).body.text.**length
>>> #GF0TARWCJU hasRichTextToolbar').body.**text.length
>>>  # delete text by backspacing.
>>> @browser.frame(:class=>/gwt-**RichTextArea/).send_keys [:control,"a"],
>>> :backspace
>>>  end
>>>
>>> Is there a better way to do this with watir-webdriver?
>>>
>>>
>>> Image Included:
>>>
>>> Thank you,
>>> Joe
>>>
>>>
>>>
>>>  --
>> Before posting, please read http://watir.com/support. In short: search
>> before you ask, be nice.
>>
>> [email protected]
>> http://groups.google.com/group/watir-general
>> [email protected]
>>
>
>  --
> Before posting, please read http://watir.com/support. In short: search
> before you ask, be nice.
>
> [email protected]
> http://groups.google.com/group/watir-general
> [email protected]
>

-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

[email protected]
http://groups.google.com/group/watir-general
[email protected]

Reply via email to