Keys Action (iOS Objects)

Applies to TestComplete 15.64, last modified on May 16, 2024
This method is available in legacy mobile tests that work with devices connected to the local computer. To learn how to simulate user actions in newer cloud-compatible mobile tests, see the Simulating user actions in tests section.


The Keys action selects (focuses) an object and types text into it.



TestObj A variable, parameter or expression that specifies a reference to one of the objects listed in the Applies To section
Keys [in]    Required    String    
Result None

Applies To

All iOS objects

View Mode

This method is available in the Object Browser panel and in other panels and dialogs in both Basic and Advanced view modes.


The method has the following parameter:


The text to enter.

Result Value



For IOS 13:The Keys action might not work if the iOS TextField control is set to disable text copying (secureTextEntry = true) and if an input string contains symbols from a language that differs from the keyboard language. In such cases, use the SetText action instead of Keys.

See Also

Testing iOS Applications (Legacy)

Highlight search results