iOS - What is the best and reliable way to clear all characters

Hi all, I do my first steps in automation for iOS with EggPlant Functional.

I’v been searching for a reliable and fast method to select an input field and clear the whole content.
It seems there is no function like “ClearKeys” as for webelement.
What would you recomment?

Regards, Ruediger

Hello Ruediger!

You could try the following:

set the mousedoubleclickdelay to 1
tap text:“Yourtext” //click on the text to be found - Menu appears
Click “Select” //select “Select”
Typetext backspace //Delete selection

You could also try ClearKeys (webName: “Text Field”) - I haven’t tried it yet!

Hello Blandine!

Thanks for the hint. I will try.
Why shall the mouseDoubleClickDelay affect the tab operation? Tab is like click, isn’t it?

I was browsing the Eggplant Documentation and that is where I came across the suggestions to add it: (Run Options Global Properties | EPF Docs)

I tested it on a virtual mobile through SauceLab, so my iOS was really slow.

" The default value of the MouseDoubleClickDelay is quite fast, sometimes too fast for certain apps, so you might find that your app does not respond to double-clicks or double-taps that use the default value. Adjusting the MouseDoubleClickDelay to a speed appropriate for your SUT ensures that the SUT recognizes the click or tap event."

Ok, but your proposal has no double click or double tab.

Correct. I am unable to make it to work with a double tap, just tap. I can only get the “select” option to pop up, instead of the “highlighted” option which does the same thing really. I am testing this on Iphone 11. What device are you using?

I’m using iPhone emulator with iOS 14.5.
It is really tricky to get it reliable…
Sometimes it works fine with 1 click, sometimes I need 2 clicks.
Nevertheless, thank you very much for your support!